I am making a template system and everything seems to be going well up until I have to loop in a variable where things starts to go weird. I need ideas on how to solve this.
It is not picking up variables where it changes within the loop.
Ie...
Code: for ($i=0;$i<3; $i++) {
$body->loop_blocks('test_area', array(
"TEST" => $i,
"TEST2" => $test2)
);
}
It picks up TEST2 variable as it remains constant, but TEST variable remains at 0.
Code: function loop_blocks($blockname, $array = array()) {
$this->$_blockdata[$blockname . "."] = $array;
foreach ($this->$_blockdata[$blockname . "."] as $tags => $data) {
$this->_looparray[$blockname . "."] = ereg_replace("{" . $tags . "}", $data, $this->_looparray[$blockname . "."]);
}
return true;
}
$this->_looparray[$blockname . "."] is where a particular block of HTML Code needs to be repeated for a loop.
Any thoughts?
upload image name with extension using php
hi frds..<input id="file1" type="file" name="file[]" >upload image show path like C:\Documents and Settings\My Documents\My Pictures\images0056.jpgi need
How to add advertisment on top of videos
Hello,I was told that i should find the answer for this problem in this forums.I searched a lot but i couldnt find the solution .What i need to do is to add ads on top of the videos i have
foreach and array need help combining
Hi guys.Here's the codeCode: array( 'tag' => 'code', 'type' => 'unparsed_content', 'content' => '<div
Count
Getting the same count everytimeCode: $visitquery = mysql_query("SELECT COUNT(*) FROM visitors WHERE ownerkey = '$uuid' & region = '$selected' AND `date` < DATE_ADD(CURDATE(),
socket makes browser hang...
I have a socket server, and I am having a problem at the moment...A browser sends a http header request to the server, but... some browsers send one request for one file, and others want 2. For
Php - mysql select?
hi, i have this code:Code: <?phpsession_start();// dBase fileinclude "config.php";if ($_GET["op"] == "login") { if (!$_POST["username"] ||
Ariba 9r - SAP MM Integration
Hi experts,
need to apply an if/else statement to Tim Thumb script
Not sure how to work this. I essentially want to call a variety of image sizes based on which stylesheet a user chooses from the administration backend of a wordpress theme. The sizes of the images
please help me in this update statment
hi every one
Changes to hosting company's server has affected web contact form
I started a thread a couple of months ago about the contact forms on my client's website. Basically he wants me to overhaul the SEO on his site. However, there were problems with the PHP contact forms