Finding digits in variable containing text, and IDing them


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

$romanstock = "http://www.remoteprice.com/data.asp?storeid=123&itemcode=456&type=2";$contentsstock = file_get_contents($romanstock);
The above code, when rendering $contentsstock, renders this:
Quote:var cText = '13' document.write(cText)

'13' could be 1 or even 189.

I need to get those digits out of there, and then query them, ie;
Line number On/Off | Expand/Contractif ($contentsstock >= "2") { echo "this is 2";}

I think I know how to strip out characters from character 10 (for example) up to character 12, but this quote could be 1, 2 or 3 digits.

Can anyone help me here please?

51 Like 10 Dislike
Previous php-forum Next php-forum
Other php-forum

How to search for several parameters from objects in a database?
I have a database with lots of information about objects.
Now I would like to search for 4 or 5 p

Mastering Regular Expressions, Third Edition, is available.
The Third Edition of Mastering Regular Expressions is available.

QuoteThis third edition is 5

Output Full URL of Current Page
Let's say I am currently viewing a dynamic page:

http://www.mydomain.com/directory/index.php

True way to see if action was successful?
If this is a good way to see if action was successful to continue:

Code: function changeGa

php code generators
All

Whilst enjoying learning a new language i have come accross a number of free code generat

Not loading image
When this function gets loaded it doesn't load the image just trying to figure out why.

Code:

Help with Password Encoding/Decoding?
Trying to design a "change password" tool. On my signup code I'm using base64_encode, now

Expandable Post Code
Hi,

Hope you can help. Which currently I haven't upgraded to connect to a mysql server, so i

gmdate() - want 1 hr before time
Hi,
I am using php gmdate().
Now I am entering all dates in my dbase using gmdate("Y-m-d

modifying a property of an object from a different class
I have 2 classes:
- Math
- Distance

in my math class, I have this line:
$distance =

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