Hi Folks,
I have been using Micah Carrick's PAYPAL IPN class till now for
web_accept
but now one of the Client wants to integrate the Recurring method into it.I tried using the same stuff but unfortunately was not so successful this time.
I am trying to connect to the Paypal recurring method.Following is the code by which I tryin...
i.e. - i want to return a string "yellow" using something like xpath expression "//banana/@color" and the following example xml...
<fruits>
<kiwi color="green" texture="hairy"/>
<banana color="yellow" texture="waxy"/>
</fruits>
$fruits = simplexml_load_string(
'<fruits>
<kiwi color="green" texture="hairy"/>
<banana color="yellow" ...
How to correct the Flaw in this function
class MyClass {
private $_callingscript;
public function __construct(){
$this->_callingscript= basename($_SERVER['SCRIPT_NAME']);
}
public static function Setvalue($k,$v){
if (!empty($k)) {
$_SESSION[$this->_callingscript.'_'.$k]= $v;//This doesnot wo...
Given a block of text, I need to parse it for the existing of a keyword. Then on the first appearance of the keyword, I need to wrap bold tags around it (if it doesn't already have them), on the second appearance of the keyword, italics, and on the third, underline.
Example using the keyword "help":
This is some text with the keyword "...
I currently have a class that sets the current time when an object has been created from it. After the object has been created, I have code that goes into an infinite loop that sleeps once every second. All this is triggered by a user going to a web page (so at this point, your browser would just be waiting). Now, if the user stops th...
I have two existing scripts that work fine as individuals.
The main script is Perl. I wish to execute the PHP script from a sub in the Perl script.
Usually, the PHP script is just run via direct url e.g. http://me.com/phpscript.php?foo=bar
I would like to just call the PHP script from the Perl and pass the foo var so, I don't need to ...
we are doing project currently on php and we want to use cassandra no sql database and is there is any API available like MYSQL,LAMP?
...
Given a block of content, I'm looking to create a function in PHP to check for the existence of a keyword or keyword phrase inside an h1-h3 header tags...
For example, if the keyword was "Blue Violin" and the block of text was...
You don't see many blue violins. Most violins have a natural finish.
<h1>If you see a blue violin, its real...
This is probably a simple answer, but I was curious if you have php code like say this:
if($_SESSION['id'] == '000001' || $_SESSION['id'] == '000002') {
Could those values be grouped somehow? My thoughts would be something like:
if($_SESSION['id'] == ('000001' || '000002')) {
Not a huge deal, just wondering if it is possible. If no...
Hello everyone.
I currently have to implement a query on a postgres database using a prepared statement. My current code looks like this:
$arrFilter = array("", "");
$result = $db->prepare("select_music", "SELECT * FROM tblmusik WHERE lm_titel LIKE '%" . "$1" . "%' AND lm_text LIKE '%" . "$2" . "%');
( db->prepare() just executes p...
Hello,
I'm trying to use preg_match_all to return an separate arrays for various elements in a CamelCase string.
In my example, I'm attempting to obtain the prefix of a string in one array and everything else ( the camelcase portion of the string ) split up into a second array. For instance, get_BookGenreTitle is supposed to return get_ ...
I would like to use php to pass a keyword phrase to a function and have the function parse a block of text and return the keyword density of the input phrase as a percentage of the total word count of the text block.
...
Hi,
I want to download (or simply file_get_contents) for 5 places. I wait say 1.2 sec for each that means in total 1.2X5=6 seconds. I want to save waiting time. I thought I could wait 1.3 sec is enough. How can I approach?
...
Trying to print my custom post type's taxonomy but without the link. Tried this, but doesn't seem to work, any suggestions?
$text = the_terms($post->ID,'type','','','');
echo strip_tags($text);
Any help would be greatly appreciated... I'm about to start punching babies.
...
Hi!
I am building a form generator/builder for Zend Framework. It is for a client, and because the client wants to build forms without going into code, I need a drag&drop interface. The user has to be able to drag&drop predefined Form elements into a container to create a form. This is the easy part, which I've almost solved myself.
The...
I have a page, home.php. On the page, I have CSS tabs tab1 and tab2. The tabs are on the same page not different pages. I want the content of tab2 to display whenever I click the submit button in the content of tab2, not take me back to tab1. How can I use JavaScript to implement this behavior?
<html>
<head>
<title>home</title>
</head>
...
I'm working on a project where a Windows web server running PHP is communicating over a very slow connection with a back end Linux server running an application written in C++. Because the connection between the two machines is so slow, I'd like to compress the traffic moving between them.
I've gotten to where I can compress a string, ...
I have a field to input your friend's name and search him up to add him as friend.
The problem is that if you are not sure how to spell his name like:
Kris instead of Chris for example.
I think the right way to do this is use RegEx but I don't know how...
How can I handle those kind of typos in PHP ?
(if it isn't possible in PHP then...
Hi!
inside the checkout onepage billing.phtml I have to do several checks and even remove or add stuff to the cart.
But I don't seem to find how to do that
how can I change the cart from within an template?
Thanks,
Joe
...
Has anyone come across a CakePHP system with pre-configured things like authentication with all the login/logout forms, etc? Most websites have some sort of a basic authentication system on top of which everything is built. I was hoping to not go about re-inventing the wheel setting up the most common pages like login, logout, forgot-pas...