net can help me resolve this, i need to show an image based on a
parameter in the url.
http://www.mysite.com/modules/news/i...hp?storytopic=[value]
Where i have numeric values to say 5 max... so if storytopic=1 shows a
diferent header as if storytopic value where 2, or 3 for example.
i got this from the web....
Expand|Select|Wrap|Line Numbers
- function getURLParam(strParamName){
- var strReturn = "";
- var strHref = window.location.href;
- if ( strHref.indexOf("?") -1 ){
- var strQueryString =
- strHref.substr(strHref.indexOf("?")).toLowerCase();
- var aQueryString = strQueryString.split("&");
- for ( var iParam = 0; iParam < aQueryString.length; iParam++ ){
- if (aQueryString[iParam].indexOf(strParamName + "=") -1 ){
- var aParam = aQueryString[iParam].split("=");
- strReturn = aParam[1];
- break;
- }
- }
- }
- return strReturn;
- }
can someone be kind enough to help me with this, that -i only assume-
must be kind of easy to someone who knows the language.
Thanks.
Rojo, DJ.
México