Jump to content

phpzone

Members
  • Posts

    135
  • Joined

  • Last visited

    Never

About phpzone

  • Birthday 09/03/1974

Contact Methods

  • Website URL
    http://www.phpzone.co.uk/

Profile Information

  • Gender
    Male
  • Location
    United Kingdom

phpzone's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. You can use marquee if you wish, however to get it to work through the validator you would have to dynamically add the marquee with javascript: <script type="text/javascript"> <!-- window.onload = function() { marquee = document.createElement('div'); marquee.setAttribute('id', 'mymarquee'); marquee.innerHTML = ' <!-- INSERT YOUR MARQUEE MARKUP IN HERE -->'; document.getElementById('marquee-placeholder').appendChild( marquee ); } //--> </script> Put some code <div id="marquee-placeholder"><!-- // marquee --></div> in your page and the above code would add a child to this with the marquee content. Using this type of method you can get code to validate right up to XHTML 1.0 (possible 1.1)
  2. It would be equivalent to c:\www\config_files\file.php
  3. print "<p>Your password reminder will be with your shortly. Thank-you.</p>"; print "<meta http-equiv=\"refresh\" content=\"2;url=http://www.sitename.co.uk\">"; You cannot do this. A meta http-equiv should be in the top of your page, in the <head></head> section. However, I think you should be looking at using code such as: <?php exit( header('Location: http://www.sitename.co.uk') ); ?> Note, you cannot send a header if you have printed _anything_ to the page. So to avoid, turn output buffering on at the top of the page and then clear the buffer if you need to redirect: <?php ob_start(); print <<<_HEADER Welcome to so and so site.... _HEADER; // // do lookup for email address etc. // if ( $email_not_found ) { ob_clean(); exit( header('Location: http://www.sitename.co.uk/register') ); } else { // do email stuff print <<<_THANKS Your password has been reset and a copy of the new password sent to your email address. _THANKS; } ?>
  4. Perhaps you need to add a "user_group" system as well, so that you can check what group a user is in and based on that ask them for the password again. You will need a way to check whether they have entered a password for a section already, perhaps again you could add a 'sections_auth' array into your $_SESSION and when they auth in a section, add it's ID in there.
  5. This is all great feedback, thank you. I will take all ideas on board and come back with something else, probably in working form eg. XHTML/CSS/PHP this time. Thanks everyone, you are what makes phpfreaks so great
  6. Appreciate the feedback. True, latest version part is a gimmick. I disagree that static layouts are not used, see the new bbc.co.uk. I'm going for something that is like my wordpress site, which is in the same format. However I was thinking of doing a switchable CSS template, so a more fliud design could be done too, point taken on board. Anyone else?
  7. Hi everyone I've just been working on a graphical layout for my new site design and I wondered if anyone would like to comment? No code here yet, this is just a graphical mockup for commenting on. Thanks! http://www.phpzone.co.uk/phpzone_mockup.png
  8. Other than a book I also strongly recommend: http://hudzilla.org/phpwiki/index.php?title=Main_Page
  9. Ummm.. Backup... Download Ubuntu Studio... Install... Voila ;-) Same OS at both side. I'm joking, but it is an option, you can dual boot. And also... Download install Eclipse (apt-get install eclipse) Download install Aptana and Aptana PHP Plugin (add to update sites on eclipse and download through eclipse update) Apache2... apt-get apache2 PHP5.... apt-get php5 etc. etc. etc. ...
  10. <?php $xmlstr = <<<_XML <?xml version="1.0"?> <Catalog> <Category> <Name>Business to Business</Name> <Site> <Id>Creed</Id> <PopularityRank>4366</PopularityRank> <Description>A simple desc</Description> <HasRecurringProducts>true</HasRecurringProducts> <Commission>75</Commission> </Site> <Site> <Id>Creed 2</Id> <PopularityRank>5000</PopularityRank> <Description>Another simple desc</Description> <HasRecurringProducts>false</HasRecurringProducts> <Commission>7400</Commission> </Site> </Category> </Catalog> _XML; $xml = simplexml_load_string( $xmlstr ); $sites = $xml->xpath("/Catalog/Category/Site"); foreach ( $sites as $site ) { echo "<p>{$site->Id} = {$site->Commission}</p>"; } ?>
  11. Store the details in a Session variable. I usually use the product_id and the quantity, its all you need to store. $_SESSION[ $prod_id ] = $quantity; it shouldn't matter whether they are logged in or not.
  12. Can we see some code, preferably, where you retrieve your variables, where you insert to db and where you validate. Ta.
  13. <?php mail( $recepient, $subject, $mail_body, "From: {$sender}"); ?>
  14. Ok. I don't see the reason for having to 'find' things. I've done this and usually on my sites I have a structure like: /images/ /classes/ /templates/ header.php index.php config.php footer.php My can you not have a standard structure, keep your image.php in /images/ and your class in a folder? Then have a variable in config.php that defines your BASE_PATH and use that?
×
×
  • 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.