Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About Jamess

  • Rank
  1. try looking at http://www.thescripts.com thats quite a good resource site..
  2. Jamess

    Erm... Complicated.

    There are a couple of ways to do this. Firstly, if you only have a couple of outcomes that you want to occur, or if you're controlling the outcome (using them as links and such) then you can define them simply in php.if ($link == "home") {include ();} This would mean when page.php?link=home is accessed, the code between {} is called, in this case, include().This is how I would do it, if you only had a couple of outcomes.. if ($link == "home") {include ();} elseif ($link == "work") {echo "work";} elseif ($link == "") {echo "no ?link specified";} else {echo "Invalid ?link specified";} $link == "" means that no ?link is specified, so any code between the {} corresponding with that, would happen if they directly accessed the page itself, eg, http://yourdomain.com/thispage.phpelse {} means that if the ?link they specify isnt empty, or doesnt match a $link you have specified, this code will be called upon..There is another way to do things, which is a bit more PHP complex, but is alot easier when you have a lot of outcomes.. if(isset($_GET['id'])){$query = "your mysql query WHERE id = '{$_GET['id']}'";$result = mysql_query($query);while ($row = mysql_fetch_array( $result )) {// in here is the code that would be executed, specific for each query result, for example..echo "You just typed in:";echo $row['id'];echo "<br />This item, has the name:";echo $row['name'];echo "how cool is that!"; This is for when you have a lot of outcomes, change query to your mysql query.. $row['']; must match your mysql databases column names, so $row['name']; would be the column `name` from your mysql database, when the records ID matches ?id=Hope this helps
  3. Jamess

    Opening a link in PHP

    <meta http-equiv="refresh" content="1;url=http://google.co.uk">1 represents the number of seconds before your new page will load. After url= should be the full (not relative) adress of your file.. just to keep it simple!
  4. If you have a client, and your struggling with this, why did you take it on? Copying/following a tutorial may get it done, but then couldnt your client just follow the tutorial instead? If I was a client, I wouldnt really want to pay for someone who just copied something simple..
  5. try changing the height to min-height..(of .content) this is done automatically by some browsers, but not all; it should fix that problem..The other issue I cant see, or make, post another draft to demonstrate? If its only a few pixels I wouldnt bother that much, fixing it could take a lot of time/effort, and for 1-4px, there isnt really much point.
  6. Jamess

    Windows live mail

    a php/sql based email system wouldnt offer anything near the functionality that proffessional companies can offer via AJAX; hence why they use AJAX and other stuff on top of php/sql.. It works fine for PM (personal message) type systems, but with emails stuff gets really tricky.. I wouldnt recommend you try it..
  7. Jamess

    Space between text

    is the HTML for a space.. failing that you could use a span or div (style="padding\margin: #px;")
  8. Jamess


    Ive sorted the IE Issue, but now everything else has broken; wonderful logic: you either have it IE effective, or everything else. This is really annoying, because although a bigger majority of my sites traffic is IE, I USE OPERA&FIREFOX, so everyone BUT ME(and those with sense) will see the correct site layout!Im really lost how FF and Op are getting the error, how is it so hard to render min-height? If anyone has has this problem or knows of it please let me know!
  9. Why not use an unordered list?<ul><li>Name: <input></li><li>Email: <input></li><li>Message: <textarea> </li> And to control it: ul { list-style: none; }li { display: block; border: 1px #000 solid; /*if you want a sort've table border effect*/ margin-left: 20px; }input { background: none; text-align: center; } The margin-left: value will denote how far from the left of the screen (in either pixels or %) the li forms. You could set a margin-top: to control how far below each other, and other items, they appear too.
  10. Jamess

    two questions

    try using a script resource site, thescripts.com or something like that. Like I said before a google search would bring up tons of examples, using your specifics as keywords.
  11. Jamess


    If you dont get the title, im having an IE issue, and im guessing im the only one who thought the title was a little bit clever For some reason, the only way I could get my sites containers to work, is to set the body at over 100%. (its at 140%). Opera and FF render this exactly the same, however IE7 and 6 ( i think ) create a much smaller window. Ive tried IE specific comments, CSS hacks and stuff; to no avail. Is there anyway I can get around having to set body to 140%, or get around the IE issue?CSS: http://www.firstcarfund.co.uk/includes/csss.cssPage: http://www.firstcarfund.co.uk/index2.phpIf you dont understand whats going on, the whole huge list of divs, its to create the rounded box effect.. anything enclosed in the box is inside <div class="boxcontent">
  12. Jamess

    two questions

    for the first, if you just want a simple form there are thousands readymade, just google form or something..image via background can be done via css the following: body,html { background: url(url relative url to image); } or background-image: url(url relative to image); }
  13. for the problem of stuff dissapearing under your content, take a look at the CSS z-index property
  14. Wouldnt it make more sense and be easier to just have<a href="index.html" class="nav1">home</a>
  15. Im trying to randomly sselect 9 options from my db..Is there anyway to do this through an array? $query = "SELECT id,name,date,type,file ". "FROM `games` ". "WHERE `type` = 'Action'". "LIMIT 0 , 9";$result = mysql_query($query) or die('Error : ' . mysql_error());$numaction = mysql_num_rows($result);$i=0;while ($i < $numaction) {$id=mysql_result($result,$i,"id");$name=mysql_result($result,$i,"name");$date=mysql_result($result,$i,"date");$type=mysql_result($result,$i,"type");$file=mysql_result($result,$i,"file");echo "<li class=\"games\"><a href=\"#\" onclick=\"java script:popUp('/arcade/$file')\" title=\"Added On: $date\">";echo "$name";echo "</a></li>";$i++;} I havent come into randomness in anyting in the past, was hoping for some help in this case, all ive come up with so far is: $number = rand ('0','$numaction'); to generate the actual number.. (each inclusion of $number would generate another random number, right?)
  • Create New...