Lowyat.NET Forums

Welcome Guest ( Log In | Register )

 
RSS feedBump TopicClosed TopicStart new topicStart Poll

Outline · [ Standard ] · Linear+

> content change help!, header and footer remains...

xi4n9
post Nov 1 2009, 12:40 PM
Show posts by this member only |This post's rating (0+, 0-) | Post #1


Getting Started
**

Group: Junior Member
Posts: 110
Ratings earned: 0+, 0-
Ratings given: 0+, 0-

Joined: Feb 2008





Currently im making a website for my assignments, and i i have a flash button menu on header, i wanted those button to change only the content, and the rest of the header and footer still remains at the same page... can i do that?my webpage using xhtml,javascript, and ASP.net and my css layout is separated... icon_question.gif
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
puaka_astro
post Nov 1 2009, 03:57 PM
Show posts by this member only |This post's rating (0+, 0-) | Post #2


Getting Started
**

Group: Junior Member
Posts: 130
Ratings earned: 0+, 0-
Ratings given: 0+, 0-

Joined: Jun 2007





1. use iframe, frame make the flash button link attribute target to iframe/frame name

2. use ajax to change the content, make a javascript function for this ajax call, and add onclick event to flash button which calls this function
User is offlineProfile CardPM
Go to the top of the page
+Quote Post
xi4n9
post Nov 1 2009, 05:23 PM
Show posts by this member only |This post's rating (0+, 0-) | Post #3


Getting Started
**

Group: Junior Member
Posts: 110
Ratings earned: 0+, 0-
Ratings given: 0+, 0-

Joined: Feb 2008





thanks! can u hint me with what command line i need to input to my flash button? i had no knowledge about ajax, and i did not know how this works in flash buttons... =( i had this code:

<html>
<head>
<script type="text/javascript">
var xmlhttp;
function loadXMLDoc(url)
{
xmlhttp=null;
if (window.XMLHttpRequest)
{// code for IE7+, Firefox, Chrome, Opera, Safari
xmlhttp=new XMLHttpRequest();
}
else
{// code for IE6, IE5
xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
}
xmlhttp.onreadystatechange=state_Change;
xmlhttp.open("GET",url,true);
xmlhttp.send(null);
}

function state_Change()
{
if (xmlhttp.readyState==4)
{// 4 = "loaded"
if (xmlhttp.status==200)
{// 200 = "OK"
document.getElementById('T1').innerHTML=xmlhttp.responseText;
}
else
{
alert("Problem retrieving data:" + xmlhttp.statusText);
}
}
}
</script>
</head>

<body onload="loadXMLDoc('test_xmlhttp.txt')">
<div id="T1" style="border:1px solid black;width:300;padding:5"></div><br />
<button onclick="loadXMLDoc('test_xmlhttp2.txt')">Click</button>
</body>

</html>

(it's from w3schools, and i think this is what i want, but i doesnt wanted to create a button to link to my file, so i would like to put a phrase into my flash using the method u provide)
User is offlineProfile CardPM
Go to the top of the page
+Quote Post

Bump TopicClosed TopicTopic OptionsStart new topic
 



----debug section please ignore----
Lo-Fi Version Time is now: 25th November 2009 - 11:02 AM
All Rights Reserved 2003-2009 Vijandren Ramadass (~living on a prayer~)