replacements


Posted on 16th Feb 2014 07:03 pm by admin

I have a variable in my PHP script like

ASSFDDDDDDDDDDDDDASDDDDDDDDARYTRHKKHHHHHHHHHHH and positions 5-10

Did you know?Explore Trending and Topic pages for more stories like this.
I want to replace these positions with another color .

$newpat="<font color=blue>$pat</font>";

can someone tell me what function to use and how, I tried string_replace, but didn't work. I did not know hoe I could tell it to replace specific positions and multiple at a time.
No comments posted yet

Your Answer:

Login to answer
264 Like 15 Dislike
Previous forums Next forums
Other forums

Preg_match with an array
is there an away to use preg_match with an array?

i want to check a string with an array to s

compile php5 with DOM
Hi,

I can't manage to compile php 5.3.0 from source on Windows to include DOM,
in spite of

Coding question?
Hey guys, I have a quick question. If I want to make a way for people to pay for health in my game,

extending tidy
I have problem with type-hinting and extending tidy. This code creates error:
Code: class cMyTidy

Sessions work for me and not others?
I'm having a bit of bad luck with sessions. In the past they have worked fine for me, but this time

Need help with simple code, back and forward buttons.
Basically, I have a set of pages in a folder, which have the title somephrasehere_09.php, somephrase

How to kill asynchronous postback / current postback?
Hi,here is my problem:I have a web site with many pages of which some may take time to process resul

simple script won't work. Please help
I'm new to php, and I am having trouble displaying a simple script in my web browser. My php code ex

Multiple Do / While Statements?
I'm still very new to PHP, and running in to a problem when trying to execute a do/while loop inside

Session login issue
I'm wondering how to fix a problem I'm having with a session-based login system

Say I go to h

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash