In Magento I'm creating a custom module and would love to be able to filter automatically by the datetime column so that the intial grid listing shows only entities related to "todays" date.
Here is my datetime column:
$this->addColumn('ts', array(
'header' => $hlp->__('Activated'),
'align' => 'left',
'index' => ...
When I am going to upload a file, my $_POST variable knows the file name, but the $_FILES variable is null. I've used this code before, so I'm really stumped.
Here's what I'm using for input:
<label for="importFile">Attach Resume:</label>
<input type="hidden" name="MAX_FILE_SIZE" value="10000000">
<input type="file" name="importFile" i...
I have an array of checkboxes that I edit at once to set up a 'tinyint' field. the problem comes in when i uncheck the checkbox and post the vales to mysql. since it posts an array of checkboxes and another parallel array of values to edit, unchecking a checkbox results in the 0 value been ignored by PHP_POST and hence the checkbox array...
Ok. I am just starting to use soap and my first problem is installing it. I got this error:
Fatal error: Class 'SoapClient' not found in /home/user/mysite.com/path/to/file.php on line 16
I am hosting my site in DreamHost and ask the guys there. But they told me that they don't support any third-party installation.
Does anyone has t...
Hay I'm using PHPMailer to send some simple emails, however the function SetFrom() doesn't seem to work, even though the code I'm using is straight from phpmails docs (http://phpmailer.worxware.com/index.php?pg=examplebmail)
Here my error
Call to undefined method PHPMailer::SetFrom()
and my script
require_once('inc/phpmailer/class.p...
Does anyone knows a web application security scanner for mac and easy to install?
...
UPDATE:
I know I can use <ol> directky in the output but I remember using something like:
<?php echo $i++; ?> when I worked on a wordpress blog once. Every time I inserted that tag a number greater than the previous appeared so I basically did:
<?php echo $i++; ?> Text
<?php echo $i++; ?> Text
<?php echo $i++; ?> Text
I'm a front en...
I have a very simple query
$this->db->select('id, title');
$this->db->order_by('id', 'DESC');
$query = $this->db->get('journal');
foreach($query->result() as $row):?>
<ul>
<li><? echo anchor("journal/arc_journal/$row->id", $row->title);?></li>
</ul>
<? endforeach;?>
The data link it produces is perfect, but when my list is displayed ...
Hello,
I am trying to use the http_get function. But I get a undefined reference error. I understands that this means the function can not be found. However I do no know how to fix this? Could somebody help?
Cheers
...
I have solved this problem, I just need to know what to do. I get the above error because I just realised that the class is being run as class::function($values) instead of class->function($values).
Does anyone know how to convert this function to instantiate the class then run the function with values?
private function _load($values=n...
Hello! I am actually trying some codes i found from http://php.net/manual/en/class.com.php
<?php
// starting word
$word = new COM("word.application") or die("Unable to instantiate Word");
echo "Loaded Word, version {$word->Version}\n";
//bring it to front
$word->Visible = 1;
//open an empty document
$word...
I have a page that creates an associative array, then passes it as a hidden value to a new PHP page. I have a foreach loop waiting to iterate through it but it coughs up an "invalid argument" error, as if the page doesn't know the value it's working with is an array (Despite "print" showing simply "Array"). This is essentially what I hav...
I have written a very very very simple!! script in php. header redirection not working.
1- encoding : UTF-8 without BOM
2- with adding ob_start() the problem is countiueing.
What is wrong in my code;
login.php:
<?php session_start();
require_once("funcs.php");
db_connection();
$username = $_POST['username'];
$password = $...
Using a great script to grab details from imdb, I would like to thank Fabian Beiner.
Just one error i have encountered with it is:
Use of undefined constant sys_get_temp_dir assumed 'sys_get_temp_dir' in '/path/to/directory' on line 49
This is the complete script
<?php
/**
* IMDB PHP Parser
*
* This class can be used to retrieve data...
Anyone know a good external link tracking script ? IE. to catch links and referrer stats through a posted img tag, even if there's no actual IMG. I know how PHP works in this matter, but I'd hate to code it from scratch.
...
First, a brief example, let's say I have this "/[0-9]{2}°/" regex and this text "24º". The text won't match, obviusly ... (?) really, it depends on the font.
Here is my problem, I do not have control on which chars the user uses, so, I need to cover all possibilities in the regex /[0-9]{2}[°º]/, or even better, assure that the text has ...
Hello, I am trying to create a dynamic sql query, in which the users clicks a button(link) and the id of that link is sent to the sql query. I would like to accomplish this using jquery. But, being very new to both jquery and PHP, I am finding it very difficult to get this to work properly.
Firstly, I should mention that I am using this...
I'm considering switching to mysqli for all my php projects. The way my code is written (I run very simple websites and built my own basic framework which I use across all of them) I shouldn't have too many problems modifying the functions and classes.
However, i've only heard positive things about prepared statements, bar a few grumbli...
Hello
Hoping that using something like this demo it is possible to drag items within and between two columns, and update their order either live or with a "save" button to MySQL. Point being that you can make changes and return to the page later to view or update your ordering.
http://pilotmade.com/draggable2.html
Doing it for just on...
For smarty's html_options function, is there a way to avoid having to do this (other than not using smarty that is)?
{if $smarty.post}
{html_options name=option_1 options=$options selected=$smarty.post.option_1}
{else}
{html_options name=option_1 options=$options}
{/if}
I realize that it won't show up in the template, but it s...