Page 2 of 2
Re: How to display a webpage from another domain in our php
Posted: Wed Mar 09, 2011 5:42 am
by VladSun
krieya wrote:I felt that it can be done if we can change the DOM in our browser using javascript or any other stuff however to access the DOM from other domain is causing cross domain issues.
Do I have any way to get this work done?
XSS is one of the biggest issues in browsers, so I really doubt you can bypass it.
I mean to use cURL as a proxy to fetch the content then display it under your domain. Then on form submittion / link click pass data to your cURL proxy which in turn submits data to the target site, get the contents and display it under you doman again. cURL will not "press" buttons, etc.
Not a very easy task to do though, becuase probably you will have to rewrite links, form action parameters etc.
Re: How to display a webpage from another domain in our php
Posted: Wed Mar 09, 2011 11:21 am
by Jonah Bron
Oh, what you wanted wasn't clear before. I thought you literally wanted to log into Yahoo email.
Greasemonkey is your best bet. It's just a FF addon, so you don't need any administrative privileges to install. Just go here and click "Add to Firefox".
https://addons.mozilla.org/en-US/firefo ... asemonkey/
Simple as that. Then you can write what are called "user scripts" that do whatever you want (in Javascript). Write your scripts to programmatically fill out all your forms.
Re: How to display a webpage from another domain in our php
Posted: Wed Mar 09, 2011 11:56 pm
by krieya
Actually, for testing purpose we are using IE browser hence I can downloaded GM for IE.
However we use FF,Safari,Opera,Chrome for browser testing so I am looking for a browser independent solution because we cannot write scripts for each browser.
Thanks for your guidance!!
Re: How to display a webpage from another domain in our php
Posted: Thu Mar 10, 2011 11:14 am
by Jonah Bron
Greasemonkey is just the addon to Firefox for user scripts. There are plugins available for all browsers. See this article for IE, Safari, and Opera:
http://techie-buzz.com/tips-and-tricks/ ... afari.html
Chrome supports user scripts natively. Just create the script to fill out the form, and install it in all browsers.
Re: How to display a webpage from another domain in our php
Posted: Thu Mar 10, 2011 11:25 pm
by krieya
I tried installing grease monkey for IE in my workplace and it is working very fine. Thanks alot, I feel like I have found the solution to my problem!!
Now, I want to make my own extension according to our need.
Is there any detailed step by step documentation to create a IE extention (to run our javascripts or jquery scripts). I am also planning to extend this support to firefox, opera, safari, chrome.
Thanks!!
Re: How to display a webpage from another domain in our php
Posted: Fri Mar 11, 2011 10:31 am
by Jonah Bron
You mean user script? You can read the GreaseSpot Wiki here:
http://wiki.greasespot.net/Main_Page
And at
http://userscripts.org , you can download other user scripts written by other people, and look at them as examples.
And here's a video tutorial:
http://codebazaar.blogspot.com/2010/11/ ... ey-do.html
Re: How to display a webpage from another domain in our php
Posted: Sat Mar 12, 2011 12:30 pm
by krieya
No, I mean, I want to create a new extension for IE browser.
Is there any step by step procedure documented to create our own extensions for IE?
I am planning to develop an extension that will run my JAVA SCRIPTS or JQUERY scripts that were located in my system (eg: c:\sample.js)
For example: If I click a link on my webpage, scripts that were located in my system @ c:\sample.js should start execute on the currently open browser.
Thanks!!
Re: How to display a webpage from another domain in our php
Posted: Sat Mar 12, 2011 12:53 pm
by Jonah Bron
But why reinvent the wheel? Just do it with Greasemonkey. I don't know how to write plugins for IE though.
Re: How to display a webpage from another domain in our php
Posted: Sat Mar 12, 2011 10:08 pm
by krieya
Actually, all my js scripts are in my server.
So first I will copy the script which I want to run to the local machine then the IE extension will read the copied JS and will execute them on the currently opened browser.
Since to get this task done with greasemonkey, the way it works is different however it is running the JS file in the way I want it.
Hence I want to develop a new extension for fitting my need.
Thanks Jonah Bron, for getting me all this way through!!