Jump to content

Adam

Moderators
  • Posts

    5,717
  • Joined

  • Last visited

  • Days Won

    6

Everything posted by Adam

  1. Look into the JS 'event' object, specifically 'event.type'.
  2. Adam

    preg_match

    You should be able to use preg_match_all(), but what's an example of a post with more than one quote?
  3. Why not just use a forum?
  4. Adam

    preg_match

    Why don't you store the data in seperate fields, to prevent future issues like this? You can just format the post when you return it that way. To make things a little simpler I returned the PID, DATE & NAME together then the POST separately: <?php $str ='<!--quoteo(post=279:date=Nov 26 2008, 09&#58;38 PM:name=Chaos23)--> <div class=\'quotetop\'>QUOTE(Chaos23 &#064; Nov 26 2008, 09&#58;38 PM) <a href="index.php?act=findpost&pid=279"><img src=\'images/snapback.gif\' alt=\'*\' border=\'0\' /></a></div> <div class=\'quotemain\'><!--quotec-->I didn&#39;t copy it I quoted it<!--QuoteEnd--></div> <!--QuoteEEnd-->'; preg_match('#<!--quoteo\(post=([^:]+):date=([^:]+):name=([^\)]+)\)-->#', $str, $details); preg_match('#<!--quotec-->(.+?)<!--QuoteEnd-->#', $str, $message); print_r($details); print_r($message); ?> Should think you'll be okay from here?
  5. Give htmlspecialchars() a try.
  6. Adam

    preg_match

    I'm assuming {PID}, {DATE}, etc. Will be switched for actual data? Could we see a few examples? At the moment can't really give an accurate enough solution due to too many possibilities, well you could but adding in real data could break it. For example what format is the date? Can "user" contain spaces? etc.
  7. No he's checking if $split[$count] is set, and then doing another if to check if the previous if was successful- bizarre! You could just use a foreach () loop and make things much easier.
  8. I think you are...
  9. You can just use something like: $input = $_POST['input']; $split = explode("\n", $input); foreach ($split as $line) { if ($line != '') { echo $line . '<br />'; } } You'll probably want to add a <br /> tag to the end otherwise they'll all be on the same line. Edit: Just seen the <br> you had before!
  10. At first I didn't think it worked, then looked at what HERATHEIM had said and refreshed the page; surely that's not how it's supposed to work? I think if you're going to use images you should create a small thumbnail on submission they can click on to enlarge (like on this forum), rather than it taking up so much space. When you hover over the icons I think the mouse should change to pointer to indicate it's a link and also title/alt text should pop up giving a quick description for each. I think the smileys are a little large, they should only really be about the same size of the text. Also you have 27 validation errors.
  11. Aaah... After looking them up on Google and doing some reading, it all looks a little too dodgy! Take a read here: http://blogs.computerworld.com/web_advertising_linkstar and the follow up: http://blogs.computerworld.com/seo_text_link_scams Don't think I'll go ahead with this.
  12. Hey up everyone.. I've just had a request to place a text-based advert on my web site, just I've never dealt with this kind of thing before and was wondering what you'd charge? I'll quote you part of the email: I've taken a look at their company website (http://linkstar.co.uk) and it all seems above board. Just I have no idea what I'd charge for something like this? I'm going to ask to see the advert before I agree to anything as well. Thanks for any advice you can give me, Adam
  13. I think you must have missed some of the code when you copied it over. If you look at the source, the last thing there is <!-- RECAPTCHA CODE END -->. Also as thorpe said the markup's messy!
  14. Haha, yeah I agree. You managed to pull 5 errors as well: http://validator.w3.org/check?uri=http%3A%2F%2Ftweetle.in
  15. It's not terrible, but it's not exactly good. It seems to lack any proper style and just have a very simple gray and white table layout. When you first log on you have absolutely no idea what it's for, where did the name "Cubevision" come from? Why is there a sphere logo next to the text cube? what does "Cubevision" have to do with HTML / CSS / JS tutorials and scripts? It's things like that leave you slightly confused. And I don't want to be harsh but, the tutorial content from what I've read so far isn't very good quality, not to mention it seems to be quite similar to that of w3schools.com. Personally I'd scrap the tutorials for now if you can't describe them properly and completely in your own words. Coming back to your site. The navigation is very poor, during a tutorial there's no easy / obvious way to view the next chapter, plus whilst viewing "projects" you feel lost in a world of 'sub-directory' links. I think a thumbnail strip would be ideal in these situations... The HTML behind your site as I'm sure someone will point out in greater deal, is written poorly. It's not optimized for search engines and it doesn't even validate - which begs the question, why are you writing a tutorial on HTML if you can't even write valid HTML yourself? If I were you I'd try to create a more interesting design, with completely re-written (X)HTML using DIVS and CSS for layout as apposed to tables. Re-do the logo to something that has some kind of resemblance to the name, or the company image. Ditch the tutorials. To be honest there's not much point in writing a HTML tutorial anyway, type "HTML tutorial" into Google there's over 27 million results, what's point in trying to compete? Find something unique, perhaps concentrate on producing scripts or promoting your own software more? Sorry if I sounded harsh at any point, though you did ask for critique... Adam
  16. Never heard of it...
  17. Now I think I'm going to pop off to knock one out over that lovely picture of your girlfriend!
  18. Kind of reminds me of a when you play a game (like Soldier of Fortune) and you have to pretend to sign in to some 'system' - has that feeling/look about it. Personally I think the Photoshop layer styles have been over-done. Too many shadows, badly used gradients, bevels, etc. It certainly doesn't say web designer to me, to be honest.
  19. Should check out my 3 and a half inch floppy then...
  20. How would this look within the database though, literally "google.gr/mplampla and phpfreaks.com/forums/"??
  21. UPDATE table_name SET this='that' WHERE .... Update will, update whatever records match the where clause. There's many ways to update 20 records, it's generally up to you to figure out how you'll know which ones to edit - we can't tell you. If you want better help you'll need to provide better information...
  22. Well then you were on the right tracks before. Why doesn't it work at the moment? Remove the "@" suppressing the error, could explain why it's not working. I'm still at a loss as to this though, couldn't see anything similar on that website.
  23. Really basic explanation there. How exactly would this data look if both were found? How would you 'show' both, using 2 images? Do you *only* find google.gr / phpfreaks.com / gmail.com / nothing, or is the list endless? Need more information to help you.
  24. How does it not work, what do you see? Any errors?
  25. I agree, sometimes jQuery and similar can be overkill for simple functionality. Also the 'experts' are likely to be the ones writing the frameworks, you're not exactly going to become an expert using one...
×
×
  • 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.