Re: php-5.4.10-1 / custom_from

Scott Ruckh <[email protected]> Fri, 15 Mar 2013 16:42:12 -0700
Newsgroups gmane.mail.squirrelmail.plugins
Message-ID <[email protected]>
On Wed, Jan 02, 2013 at 09:51:58AM -0800, Paul Lesniewski wrote:
> On Wed, Jan 2, 2013 at 7:48 AM, Scott Ruckh <[email protected]> wrote:
> >>
> >> Make sure the user preference setting for it is enabled.
> >>
> >> --
> >> Paul Lesniewski
> >> SquirrelMail Team
> >> Please support Open Source Software by donating to SquirrelMail!
> >> http://squirrelmail.org/donate_paul_lesniewski.php
> >>
> >
> > Thank you for the suggestion.
> >
> > Allow Arbitrary From Addresses: is "checked" for the user who is testing
> > custom_from feature.  Configuration item was unchecked, and rechecked to
> > see if it would make any difference.  Making this change did not resolve
> > the issue.
> 
> Try reverting your PHP version to confirm that PHP is not the problem,
> although, again, it should be triggering errors if this is the case.
> This issue seems to be specific to your environment, as no one else
> has reported such problems, so you might have to do some debugging in
> the code itself.  Do you know PHP?
> 
> -- 
> Paul Lesniewski
> SquirrelMail Team
> Please support Open Source Software by donating to SquirrelMail!
> http://squirrelmail.org/donate_paul_lesniewski.php
> 

it looks like this line in function cf_modify_compose_page() is not working --

$output = preg_replace('|<select name="identity">(.*?</select>\s*</td>\s*</tr>)|s',
                          '<select name="identity" '
                          . ($javascript_on ? 'onChange="for (i = 0; i < this.length; i++) { if (this.options[i].selected) { this.form.custom_from.value = this.options[i].text; break; } }"' : '')
                          . '>$1<tr>'
                          . html_tag('td', '', 'right', $color[4], 'width="10%"')
                          // i18n: string below intentionally in SquirrelMail domain
                          . _("From:") . '</td>'
                          . html_tag('td', '', 'left', $color[4], 'width="90%"')
                          . substr(addInput('custom_from', $custom_from, 60), 0, -3)
                          . ($javascript_on ? ' onfocus="alreadyFocused=true;" ' : '')
                          . ' /><br /></td></tr>',
                          $output);

The variable $output is the same (at least display wise) before and after this statement.  I added an 'echo $output' right before this line, leaving the 'echo $output' that is directly after this 
line.  On the webpage I end up with two identical outputs where the custom_from field is not present.

I do not know enough about PHP or the command being executed to troubleshoot the issue.  I was hoping you might be able to offer some tips on things to try in order to help troubleshoot.

Thank You.

Scott

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_mar
-----
squirrelmail-plugins mailing list
Posting guidelines: http://squirrelmail.org/postingguidelines
List address: [email protected]
List archives: http://news.gmane.org/gmane.mail.squirrelmail.plugins
List info (subscribe/unsubscribe/change options): https://lists.sourceforge.net/lists/listinfo/squirrelmail-plugins