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

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

Redirect not working after making a POST/GET
Hi Everyone,

I am a novice in PHP. Here I have 2 pages, one page with a textbox and button an

Curl timeout breaks script
So im having difficulties with skipping timeout error in curl
my script calls different functions

please hep to get values from a table row
can anyone tel me how I can select and get data from one row by pressing an Edit button in that row

MS are the best!!!
Visit http://www.microsoft.com/australia/windows/default.aspx?h=watch-a-demo and click the massive '

help with variable
I've got a problem, i want to echo some images depending on the $id, however for me to get that id i

problems with php variables in mysql query
i can't seem to get the following query to work.

select $q1c from $vote_rate where id = $re

Seperate team from score
I am writing a site that does a NFL Pick 'em type application and I have a feed that gives me the sc

While Problem
i am having a problem with a while statement here is the code
Code: [Select]<?php
sess

date function help
i need help with date function

Code: [Select]<!DOCTYPE HTML PUBLIC "-//W3C//DTD H

Why is my row count 0?
Here's the MySQL query i'm running. It basically pulls data from 2 tables based on some data passed.

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