I've been trying to find a solution myself but I couldnt do it so far (even tried all regexlib.com suggestions), so:
Need a regex that matches URLs like (PHP code):
http://example.com orhttp://www.example.com or
www.example.com
example.com
...
Hi,
I have this $str value :
[{\"firstname\":\"guest1\",\"lastname\":\"one\",\"age\":\"22\",\"gender\":\"Male\"},{\"firstname\":\"guest2\",\"lastname\":\"two\",\"age\":\"22\",\"gender\":\"Female\"}]
I want to split it into the following:
firstname:guest1,lastname:one,age:22
firstname:guest2,lastname:two,age:22
I tried explode (","...
I am new to codeigniter model, i try to follow steps in docs to load all user registered in my db.
This is my model: user.php
class User extends Model {
function user() {
parent::Model();
}
function alluser() {
$query = $this->db->query("select * from user limit 0,5"); //Line 30 error as in my IDE locat...
Hi,
I want to report sth every new month via email. How can i do that?
Assume that no body enters the site in all month.
Sory about my english and i'm new about php.
Thanks
B.
...
Hello all,
I am trying to write a regex that will allow me to parse CSV files that excel creates. I have noticed when you export a CSV from excel, if the field is a string it will encase it in quotes. If that string contains quotes itself, it will escape each quote with a quote!!
What I want to do is split each line that I parse into f...
$name (string) gives something like (possible value):
John II, Litten Draw
We should update $name in two steps:
Catch the words before first comma and throw them to the end of the string
Remove first comma
Create a file current_name.txt (or update if already exists) and throw to it source of $name
"John II, Litten Draw" should be ...
i'm uploading these files in apache, using php. is there any best way to make uploading faster ?
...
I asked earlier how can I get rid of extra hyphens and whitespace added at the end and beginning of user submitted text for example, -ruby-on-rails- should be ruby-on-rails you guys suggested trim() which worked fine by itself but when I added it to my code it did not work at all it actually did some funky things to my code.
I tried pl...
i use certain suffix in my variable name, a combination of an underscore and a property. such as :
$variable_html = variable that will be parse in html code.
$variable_str = string variable
$variable_int = integer variable
$variable_flo = float variable.
Do you have other visual clues? Maybe something you write for variable, functi...
Hi,
I am looking for solution where using jquery I want to display 5 records per page and need Next/Prev functionality. So when user click on next button or image it will fetch data from PHP, Mysql and displays it.
SO kind of pagination but using Next/Prev
Thanks & Regards,
web programmer
...
i'm using xdebug. but have no knowledge to extend its usability. I'm still using it for backtracing error only. Is there any use of xdebug ?
or how do you personally use xdebug ?
...
How would I go about taking a picture from a video capture card or webcam? Should I use flash to do this? I want to submit the picture via a php form and upload it to my webserver and place a link to it in my MySQL database. Is there a flash app already built that I can use to perform this?
...
I have a site where you click on a product name and it launches a URL with a filter and it returns forum posts relevant to that product name:
E.g. www.google.com/product?=blah
Instead of having to navigate to this URL is it possible to launch it in a DIV dynamically rather than the user having to click a link. Looking to develop a dash...
I have a fairly simple php/soap header question.
Here's what I need.
<ns1:Identity token="123456789"></ns1:Identity>
Here's what I get...
<ns1:Identity><item><key>token</key><value>123456789</value></item></ns1:Identity>
using this code...
$headers[] = new SoapHeader('http://qpricer.com/Services/Pricing','Identity',array('token'=...
I wrote a script in php that allows me to get a list of files in a directory as an array, parse each one for a particular string, and then it displays all of the files that contain the search string.
My IT staff won't let me install php on the server though. Can this be done with javascript without ActiveX? Everything I could find on th...
Hi all,
I cannot get an encryption class to work (it's in a seperate file in the classes folder). The code for the class is:
class SymmetricCrypt
{
// Encryption/decryption key.
private static $msSecretKey = "Hello";
// The initialisation vector.
private static $msHexaIv = "c7098adc8d6128b5d4b4f7b2fe7f7f05";
// Us...
Hi,
Hoping someone can assist with a means of implementing a "Search" routine/page that I can apply to my site that is purely a HTML website only.
I have provided a Search box for the user but unsure what the next step is, i.e. can I insert php to perform the Search of my site.
Would really appreciate any help/tutorials/links that dem...
Hi,
Hoping someone can assist with a means of implementing a "Contact Us" routine/page that I can apply to my site that is purely a HTML website only.
I am assuming this will need to be a php process to send emails from a Contact Us form but unsure how to do.
Would really appreciate any help/tutorials/links that demonstrate this.
Tha...
I'm having a problem using the PUT HTTP method with the PHP OAuth library (http://www.php.net/manual/en/book.oauth.php)
What I need to do is pass some XML as the file to be PUT, but I am not sure how to send it with OAuth.
Here's what I have:
$xml = "<data><id>1234</id><something>i am now set to this</something></data>";
$oauth->f...
I need to upload video files through Facebook application and later visualize all uploaded videos so that people can vote for a video they like. I searched and read some articles, but I still have questions that are not completely clear for me:
Is it better to use iframe or FBML
If I use iframe is it possible to use input type="file" a...