Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

General Discussion

Make this website as Your HOMEPAGE

I`m trying to find a cross-brwoser function that allow user click on it and make the website the homepage for his browser?

Any help?

7 Answers

14,517 Points

Do you mean you want a different start-up page when you open your browser rather than the default site? e.g. in Safari it defaults to Apples site and I changed it to Google.

If so go to any browser and click on Preferences. From there you will see a text field allowing you to adjust the defaulted start-up URL. Normally this is under the general tab.

Justin Witz ,

Thank you for your answer, but what I mean is different, I mean to put a button in the website and once the user click on it the script will make this website as default page for its browser.

Thank you again.

James Barnett
James Barnett
39,199 Points

Omar Ziedan - Did a quick Google and the 4th result on yielded this gem, a tutorial on Creating a JavaScript “Set As Homepage” Link

14,517 Points

Omar Ziedan thanks for clarifying. Looks like James found the right tutorial to accomplish this task. Best of luck, I'll be attempting it on my end as well for experience.

James Barnett Thank you, but I guess it`s not a cross-browser script is it ?

Justin Witz Many thanks, but I`m afraid its not compatible with all major browsers! Nice to be in touch with you guys :)

James Barnett Thank you, it also didn`t work with me, any way I appreciate your help ^_^