View Full Version : Dynamic Ajax Content; open with default page
pcbobsledder
08-16-2006, 10:28 PM
1) Script Title: Dynamic Ajax Content
2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex17/ajaxcontent.htm
3) Describe problem: Is there a way that I can have a specific page load in the RightColumn when the whole page loads.
Using the demo as an example: Instead of having "Choose a page to load." come up when you open the page; have a specific page like the Porsche page open by default?
bluemoon562
08-17-2006, 02:37 AM
You could make anything the default home page. You don't need to have "Choose a page to load" as your home page. That's just a demo.
pcbobsledder
08-17-2006, 04:45 AM
can you help me with the code to have the first link on the menu open when the pageis loaded? I figured out how to change the text, but I can't seem to figure out how to put a webpage in there. Thanks.
jscheuer1
08-17-2006, 05:29 AM
From the demo page:
You can even load an external page without requiring the click of a link, by calling the function directly:
<script type="text/javascript">
ajaxpage('test.htm', 'rightcolumn') //load "test.htm" into "rightcolumn" DIV
</script>
Change the above scriptlet's parameters to your desired page's location and loading area's id. Place it in the body section of your 'top' page, after the loading area's markup, ex:
<div id="myarea"></div>
<script type="text/javascript">
ajaxpage('myinitial.htm', 'myarea')
</script>
pcbobsledder
08-17-2006, 05:57 AM
Fantastic!! That is exactly what I was trying to do. Thanks. You're awesome.
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.