Search results

  1. W

    PHP with .htaccess

    Actually, it should be quite easy with .htaccess. It's just that it isn't guaranteed you'd be able to block/allow exactly who you want. If you store all your images in one folder, then it would look something like this: RewriteEngine On RewriteCond %{HTTP_REFERER}...
  2. W

    JavaScript problem

    @ and _ should be 64 and 95 respectively. As for your function, if you only want to allow numbers, this should work: function numonly(e) { var key = (e.which ? e.which : e.keyCode); if (key == 8 || key == 46) { return true; } key = String.fromCharCode(key) return...
  3. W

    Php Review

    As kbjr stated, unless specifically set in your php.ini, the short form for the opening tag (<?) won't work. Try changing it to "<?php" first. If that doesn't fix your problem, then you need to give more details. Saying "it's not working" doesn't tell us much, it just sounds like a Microsoft...
  4. W

    Help about Mime Magic of PHP

    Well, first I would recommend using wamp for php on windows, and then I would recommend using the fileinfo extension instead of mime_content_type(): http://www.en.wampserver.com/ http://pecl.php.net/package/fileinfo http://www.php.net/manual/en/function.finfo-file.php Wamp makes dealing with...
  5. W

    CSS troubles, please help :(

    I've never had a problem with relative positioning. From my experience, as long as you know when to use which css properties, you shouldn't end up with an unmanageable layout as you described. But anyway, Agenator, try this: #navbar { background-image: url(sliced/navbar.jpg)...
  6. W

    About making a random image.

    I'm fairly certain that's what he meant since the OP asked how the image is updated by the script. And he was saying that algorithms run to generate the image, so of course he's talking about the php. But it doesn't matter. Anyway, you're right about sites filtering files with non-image...
  7. W

    JavaScript problem

    If January is the default selected option, then the onchange event won't fire when you select it without selecting something else first. I would stick with the onchange event and just include a 'select one' option, but onclick works too I suppose. Also, if you're trying to be standards...
  8. W

    CSS troubles, please help :(

    Like hartawan said, the relevant html would be nice. But I'm gonna take a stab anyway and say to try changing the "#navbar a" definiton to this: #navbar a { width: 150px; color: black; text-decoration:none; font-size: 20px; text-align: center; margin-left: 40px...
  9. W

    help w/php mail

    Out of curiosity, what was the problem?
  10. W

    [c#] Connection to MySQL DB ?

    I only really use C# for program development, and very rarely for websites, but I believe SOURCE is interchangeable with SERVER. So try localhost for that.
  11. W

    About making a random image.

    Mattura was talking about generating images from scratch I believe. That is, for the example of an image which displays the post count, php would check the user's current post count and draw an image based on that. Like he said, sort of an image with executable code in it which modifies itself...
  12. W

    JavaScript problem

    You have an extra right curly brace in code. I would delete it unless you copied it by accident and it is valid in the context of your whole script. But anyway, first of all, you don't need to use eval() for that function. And second, you can't set an option to an integer. An option is an html...
  13. W

    help w/php mail

    Only the name showed up? Well in that case, are you absolutely sure that the fields email_txt, subject_txt, and message_txt all exist?
  14. W

    CSS positioning woes.

    Well to be honest, I can't stand designing. I hate dealing with and coding in html/css, but I studied that stuff anyway since I figured it'd be unhealthy to get into web developing and not know it :P *** Ah, right. I forgot about that. Set the position of #nav to relative and the z-index to 3...
  15. W

    CSS positioning woes.

    I think you can do that with a little relative positioning and a higher z-index. Try adding this to the css: #tabs { z-index: 2; position: relative; top: 7px; } And then wrap the tabs in a div with the matching id. I used 7px for the top property just as an example. The greater...
  16. W

    CSS positioning woes.

    Thanks, I'll look into that ;-) By the way, you've probably noticed by now, but I messed up with the images. I saved them locally, and then updated the src's incorrectly when I pasted the code. I forgot the /content/images/ part.
  17. W

    CSS positioning woes.

    Well first off, you need to make the left parenthesis a left curly brace here: a:hover(color:#ffffff;}. Then you need to move the nav div before the tabs, like this: <small> <div id="nav"> <a href="index.php?page=signin">Register/Sign In</a> </div> </small> <a...
  18. W

    help w/php mail

    You would modify the function for dataReceiver.onLoad to something like this: dataReceiver.onLoad = function() { if (this.response == "invalid") { mainTL.gotoAndStop(1); alert_txt.text = "Please check email address - does not appear valid." } else if (this.response == "passed") {...
  19. W

    help w/php mail

    It'll say that the processing passed even if it didn't since mail() doesn't throw a fatal error if it fails. In fact, it just returns false. And you do already have a php.ini file, but since you're including the From header there's nothing to worry about there. Anyway, again I don't see...
  20. W

    Help with SomeryC

    As I recall, a mod stated in some other topic that you can't chmod over 755. So you may get problems even if all your data is correct. Regardless, if you're uploading to your web root, then I believe that your upload directory should be "/home/yourusername/public_html/", and your url would just...
Top