Results 1 to 4 of 4

Thread: CAPITAL or small

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2002
    Posts
    259

    CAPITAL or small

    This code:

    1: $MESSAGE = "(img)http://site.con/photo.gif(/img)";

    2: $MESSAGE = str_replace("(IMG)", "<IMG src='", $MESSAGE);
    3: $MESSAGE = str_replace("(/IMG)", "'>", $MESSAGE);

    4: $MESSAGE = str_replace("(img)", "<IMG src='", $MESSAGE);
    5: $MESSAGE = str_replace("(/img)", "'>", $MESSAGE);

    to replace (img)http://site.con/photo.gif(/img) to HTML img code, and I repeat line 2,3
    because may be user right (IMG) Capital or small.

    Qusetion : There are any function to replace string to another string if this string capital
    or small untill I do not repeat the code.
    Last edited by prokhaled; Apr 7th, 2002 at 10:11 AM.

  2. #2
    scoutt
    Guest
    use eregi_replace instead of str_replace

  3. #3
    ricmitch_uk
    Guest
    See my other post regarding BB code.

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Jan 2002
    Posts
    259

    Thanks

    thank you too scoutt

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width