# .html?variable=value

**URL:** <https://forum.kirupa.com/t/html-variable-value/186014>\
**Category:** web dev\
**Created:** [April 18, 2006, 1:24pm UTC](https://forum.kirupa.com/t/html-variable-value/186014 "2006-04-18T13:24:30Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![GNXDan](https://avatars.discourse-cdn.com/v4/letter/g/f05b48/32.png) [@GNXDan](https://forum.kirupa.com/u/GNXDan)\
**Post date:** [April 18, 2006, 1:24pm UTC](https://forum.kirupa.com/t/html-variable-value/186014/1 "2006-04-18T13:24:30Z")

</div>

well i got this script:

```auto
<html>
<head>
<title>gionex</title>

<style type="text/css"> 
<!-- 
body { 
height: 100%; 
width: 100%; 
margin: 0; 
} 
--> 
</style>

</head>
<body bgcolor="#6ECDF5">

<SCRIPT LANGUAGE="JavaScript">
<!--
var myQueryString=document.location.search;
if (myQueryString[0]='?') {
 myQueryString=myQueryString.substr(1, myQueryString.length-1);
}
document.write(   
   '<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
'+
   ' codebase="http://macromedia.com/cabs/swflash.cab#version=6,0,0,0"
'+
   ' WIDTH="740" HEIGHT="560" id="main">
'+
   ' <PARAM NAME=movie VALUE="main.swf">
'+
   ' <PARAM NAME=FlashVars VALUE="'+myQueryString+'">
'+
   ' <PARAM NAME=quality VALUE=high>
'+
   ' <PARAM NAME=bgcolor VALUE=#6ECDF5">
'+
   ' <EMBED src="main.swf"
'+
   ' FlashVars="'+myQueryString+'"
'+ 
   ' quality=high bgcolor=#6ECDF5" WIDTH="740" HEIGHT="560" NAME="main"
'+
   ' TYPE="application/x-shockwave-flash"
'+
   ' PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"></EMBED>
'+
   '</OBJECT>'
);
//-->
</SCRIPT>

</body>
</html>

```

and it does what i want it to do, which is when you type your value after the .html it will recognise the value in flash. GREAT 😃  
BUT this bit of css:

```auto
<style type="text/css"> 
<!-- 
body { 
height: 100%; 
width: 100%; 
margin: 0; 
} 
--> 
</style>

```

now does not work (so my flash is not nicely centred), at this point i think i should tell you that i know NOTHING about html and any of this stuff so any noob help is appreciated!  
Thanks for your help  
Dan

---

<div class="post-metadata">

**Author:** ![RabBell](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/rabbell/32/340_2.png) [@RabBell](https://forum.kirupa.com/u/RabBell)\
**Post date:** [April 18, 2006, 1:33pm UTC](https://forum.kirupa.com/t/html-variable-value/186014/2 "2006-04-18T13:33:15Z")

</div>

try adding

html{  
height:100%;  
width:100%;  
}

if you know nothing about HTML then I’m concerned you’re using Flash, surely every web developer starts on HTML…unless you’re a designer I guess

try this site, designed especially for noobs  
[http://www.w3schools.com/](http://www.w3schools.com/)

---

<div class="post-metadata">

**Author:** ![Scarybug](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/scarybug/32/2863_2.png) [@Scarybug](https://forum.kirupa.com/u/Scarybug)\
**Post date:** [April 18, 2006, 1:47pm UTC](https://forum.kirupa.com/t/html-variable-value/186014/3 "2006-04-18T13:47:16Z")

</div>

What he’s having trouble with is CSS, which is relatively new to HTML. I started on HTML in '95, but it took me a while to relearn it when CSS was introduced.

---

<div class="post-metadata">

**Author:** ![GNXDan](https://avatars.discourse-cdn.com/v4/letter/g/f05b48/32.png) [@GNXDan](https://forum.kirupa.com/u/GNXDan)\
**Post date:** [April 18, 2006, 2:47pm UTC](https://forum.kirupa.com/t/html-variable-value/186014/4 "2006-04-18T14:47:36Z")

</div>

no it doesnt work  
is there an easier way of getting the variable after the .html e.g. .html?page=range to get sent to flash in an easier, simpler way? Cos i dont get any of this and have not done serious coding in html/css/java  
Thanks for your help  
Dan

---

<div class="post-metadata">

**Author:** ![bwh2](https://avatars.discourse-cdn.com/v4/letter/b/8c91f0/32.png) [@bwh2](https://forum.kirupa.com/u/bwh2)\
**Post date:** [April 18, 2006, 6:59pm UTC](https://forum.kirupa.com/t/html-variable-value/186014/5 "2006-04-18T18:59:15Z")

</div>

if your server supports php, i would use that. it’s easy to pass variables from urls to the page with php.
