Jump to content

Cassius

Members
  • Posts

    10
  • Joined

  • Last visited

    Never

Everything posted by Cassius

  1. thank you for your reply, i will try that out.
  2. Hi, I have created a php file and i would like to know if i can create this as an executable file. I searched on google and i found the php gtk, however, this only runs the php files as if they were programs, but it does not create an executable. I would like to run these kind of programs on a computer which does not have neither php nor php-gtk installed on it ... is this possible? Thank you in advance.
  3. Thank you very much for your time, it worked perfect now Just a last thing, as you can see i am putting these pages inside a div on the index page, now if a search engine puts one of the content files up as search result, and people click it, they will get to see the text, but they won't be able to surf on because it isn't shown in the parent page. is there a way to go about this ? Thanks
  4. when i clicked on the search button, i got a blank page wit Array ( [year] => 2007 )
  5. Hi, The following is the contents of my index file: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <link rel="stylesheet" href="main.css" media="screen" charset="utf-8"> <?php if (!isset($_GET['mC'])) { $file = "home.php"; } else { $file = $_GET['mC']; } ?> <title>Malta Postage Stamps</title> </head> <body> <div id="grandcontainer"> <div id="headersection"><img src="images/menuimage.jpg" alt="topbanner" width="756px" height="90px"></div> <div id="menusection"> <ul class="leftmenumainbullet"> <li class="leftmenubullet"><a class="leftmenu" href="index.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Home</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=stampcatalogue.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Stamp Catalogue</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=collectorsads.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Collector's Ads</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=references.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">References</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=articles.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Articles</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=glossary.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Glossary</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=links.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Links</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=faqs.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">FAQs</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=about.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">About</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=contact.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Contact</a></li> <li class="leftmenubullet"><a class="leftmenu" href="index.php?mC=disclaimer.php"><img class="bulletarrow" src="images/bulletarrow.gif" border="0">Disclaimer</a></li> </ul> <form method="post" action="processsearch.php"> <p class="searchheader">Search Catalogue <input type="text" name="year" value="Enter a Year"> <input type="submit" value="Search"> </form> </p> </div> <div id="mainsection"><?php include($file);?></div> <div id="clearfloat"></div> <div id="footersection"></div> </div> </body> </html> Then the processsearch.php is a file on its own, and the 2007.php file is another file on its own, which should load inside a <div> in the index file.
  6. Hi, Thanks for your reply. the script which is called processsearch.php and the file 2007.php are both in this folder C:\Inetpub\wwwroot\PostageStamps ... however, in the browser i type http://localhost/postagestamps/index.php to get to the homepage. Also, i am just testing it out, so once i get it to work i am planning to move the 2007.php to a subfolder, so that i don't have a mess in the root folder.
  7. Hi, thanks for your reply. However, when i am trying the search feature i am always getting the not found page. For example in the root folder i have a 2007.php file, so when i am typing 2007 in the search field i am getting the not found. I tried altering the code as follows, but still the same problem: <?php $userinput = @$_POST["year"]; $path = "index.php?mC=$userinput.php"; if(!file_exists($path)){ Header("Location: index.php?mC=notfound.php"); }else{ Header("Location: $path"); } ?> Any ideas what i have wrong please? Thank you
  8. I have a form which has an input field called "year", and once the submit button is clicked, the following code will run. <?php $userinput = @$_POST["year"]; $path = "index.php?mC=$userinput.php"; Header("Location: $path"); ? The above code will display a page inside a div on my main page and this works fine. What i would like to do is to see if i can alter the above code, so that if the page is not found, i will take the user to a not found page withing my index.php page. I know that it has to be done something along the if ... else statement, but not sure which keywords to use. Thank you for any help.
  9. I have a php page in which i have a <link> tag which reference to an external CSS file. I would like to know if it possible to create a script which detects the screen resolution and then based on the resolution it will point the <link> tag to the to the CSS file which fits best for the screen resolution. What i am trying to achieve is something similar to the following: if screen resolution = 800x600 then <link href=css1.css> else if screen resolution = 1024x768 then <link href=css2.css> end if Thanks
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.