Jump to content

Adam

Moderators
  • Posts

    5,717
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Adam

  1. basically, i've created a website for my boss' company. Probably the main page is the shopping page - shop.php - there's not so much a problem, just that it looks very ugly. For example, when viewing a particular model, the address looks something like: .../shop.php?c=SL-Class&m=W194&id=G4 I've seen somewhere using "mod_rewrite" (or something) you can make a better looking address, such as: .../shop.php/SL-Class/W194/G4 Anybody know anything of this? -Thanks
  2. what excactly do you want to do?
  3. For a website I recently made, I created a file called "image.php" and used a parameter ("url") to locate the image. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <title>Image: <?php print $_GET['url']; ?></title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <style type="text/css"> body { background-image: url('images/img-bk-cross.gif'); margin: 0px; } </style> </head> <body> <img src="<?php print $_GET['url']; ?>" alt="" /> </body> </html> I used this for an "enlarge image" type of thing, and because the company had all their product images the same size, I used javascript to size the window. Looked much better than having a lot of whitespace in the window. If you wanted, you could make it more adavanced by adding captions and titles. To do this, you could either assign an id to the image, then use a parameter like: "id=34" to identify the url, and caption; titles anythign else you'd want. OR, you could use the image path from the root (eg. images/catalog/34.jpg). - Obviouslly the captions and titles would be stored in a database. If you are interested in storing the ACTUAL image in the database, it would have to be some kind of binary or encryption used.
  4. I know how to use AJAX and PHP - And upload files the normal way. When i send the ajax though, how i send the file location (eg. C:\.....\myfile.ext), as it wouldn't register as a "FILE" object. - thanks
  5. Hi everyone, is there a way to upload files using PHP and AJAX? Anyway at all? - Thanks :: MODIFIED ::
  6. Adam

    Date Help

    If i had a date in the format: "DDMMYY" (for example: "251207" - christmas 2007) how can I check if that date is in the future, or already past? -Thanks
  7. number_format($price, 2); - has worked great thanks !
  8. EOF means "End of file"...
  9. I have created a shopping cart script and all works perfect, apart from the totals! They are returning as £20.5, £19.8, etc, when the last number is a 0. How do i stop PHP from removing the 0's ? -Thanks
  10. you can't. php is server side and javascript is client side. php is parsed before the page is loaded, it cannot function in the same way as javascript.
  11. hi, im trying to position a div on the screen using javascript to be in the bottom right corner .. then i want to animate the div to create a very similar effect to msn (when a contact signs in). does anybody know how i can position the div in the bottom right corner?
×
×
  • 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.