clicking on links in thunderbird e-mails, firefox can't handle php scripts
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
clicking on links in thunderbird e-mails, firefox can't handle php scripts
When I click on links (particularly those for verifying my account's e-mail address, php scripts) it tries to open them in firefox but asks what application I want to use to open them, even though they're just web addresses to php scripts. How do I enable this for Mandriva thunderbird/firefox?
the web server has to execute php scripts that usually send html coded data to the browser. Browsers themselves cannot execute php files. So you have to configure the server accordingly...
That's not enough information for someone at my level.
It sounds like you're saying the web servers are misconfigured, but that can't be the case for all of them and besides, it all worked fine in Windows. Do you instead mean that there's supposed to be a server set up on my computer in order to surf the net? This is news to me; how do I do this?
you dont need a server to surf somewhere. but the most common way to run php scripts is to run them on a http server, i. e. apache with modular support for php.
but it seems i didnt get you right. if you are surfing the web you encounter misbehaviours of your browser firefox, that does not display php-based websites as expected but offers you to download and save them instead? So maybe it helps to change the preferences of firefox->content->look for php extensions or default values...
Actually, it happened when I tried to click the e-mail link that said you'd replied to this thread. It happens with any link that's inside an e-mail in Thunderbird. Links work ok from inside Firefox (such as hotmail or webmail), but not at all in Thunderbird. If I click in Thunderbird, I get stuck in a loop of a pop-up asking what program to use (it at first wants to show me the source code), and if I click Firefox, it keeps asking what program to use.
Somewhere there is a place to specify preferred applications for browsing and email. In Ubuntu and Gnome its under System>Preferences>... Make sure thats set to Firefox.
Also on my Laptop for some odd reason a link in an email will only work if Firefox is already started.
I went into my Mandriva preferences and associated php files with Firefox, made Firefox my default browser and Thunderbird my default e-mail client and then a curious thing happened-- when I clicked on a link to linuxquestions.org's thread for this discussion, 'Untitled' windows endlessly opened in Firefox and wouldn't stop, like an endless loop. Firefox is set to restore previous sessions upon opening and the next time I opened it, the following errors were posted by the Firebug plug-in:
[Exception... "Cannot modify properties of a WrappedNative" nsresult: "0x80570034 (NS_ERROR_XPC_CANT_MODIFY_PROP_ON_WN)" location: "JS frame :: file:///usr/lib/firefox-2.0.0.11/components/nsSessionStore.js :: sss_saveState :: line 1749" data: no]
[Break on this error] oState.session = { state: ((this._loadState == STATE_RUNNING) ? STATE_RUNNIN...
This is the code to which the above error refers:
/**
* save state to disk
* @param aUpdateAll
* Bool update all windows
*/
saveState: function sss_saveState(aUpdateAll) {
// if crash recovery is disabled, only save session resuming information
if (!this._resume_from_crash && this._loadState == STATE_RUNNING)
return;
[Exception... "Cannot modify properties of a WrappedNative" nsresult: "0x80570034 (NS_ERROR_XPC_CANT_MODIFY_PROP_ON_WN)" location: "JS frame :: file:///usr/lib/firefox-2.0.0.11/components/nsSessionStore.js :: sss_saveState :: line 1749" data: no]
[Break on this error] oState.session = { state: ((this._loadState == STATE_RUNNING) ? STATE_RUNNIN...
Sounds like a JavaScript error in one of session handling plugins like tabmix, try turning it (and sessions) off, prehaps that'll help against opening windows.
As for downloading pages - look at the headers given to you by server (unfold first item under "Net" tab in Firebug) and look for "Content-Type" header. If it says "text/html" then the bug is in your browser which tries to download correctly-marked text for no reason. Prehaps thunderbird invokes it with some wrong command-line parameters?
I'd also recommend temporarily moving firefox' settings (in your home folder, inside ".mozilla") and trying the same sequence of actions. If the bug persists with clean firefox there's probably no point trying to fix it thru firefox' settings or by disabling extensions.
Sounds like a JavaScript error in one of session handling plugins like tabmix, try turning it (and sessions) off, prehaps that'll help against opening windows.
As for downloading pages - look at the headers given to you by server (unfold first item under "Net" tab in Firebug) and look for "Content-Type" header. If it says "text/html" then the bug is in your browser which tries to download correctly-marked text for no reason. Prehaps thunderbird invokes it with some wrong command-line parameters?
I'd also recommend temporarily moving firefox' settings (in your home folder, inside ".mozilla") and trying the same sequence of actions. If the bug persists with clean firefox there's probably no point trying to fix it thru firefox' settings or by disabling extensions.
but that's not all-- it looks like it's not even trying to go on the net to find this page because the address bar contains "file:///var/tmp/kdecache-[my username]/krun/27739.0.", a local file.
This time there were no errors reported relating to the endless window pop-ups (it stops if I close and re-open Firefox) but there was an error related to another link I tried (it said that w.focus was an empty variable)
here's the code it gave when I clicked on it...
Code:
//var showExitSurvey=true;
var w=null;
var TimetoPopup=60000;
window.onload=function(evt){
var clockStart;
var EnterPcomCK=get_cookie("EnterPcom");
if (EnterPcomCK==""){
//alert("Session cookie empty");
var enter_pcom=new Date();
clockStart=enter_pcom.getTime();
SetCookie('EnterPcom', clockStart);
//alert("Set Cookie with clockStart"+clockStart+" start timer");
setTimeout("show_survey()",TimetoPopup);
}
else{
var myTime = new Date();
var timeNow = myTime.getTime();
var timeDiff = timeNow - EnterPcomCK;
if (timeDiff>TimetoPopup){
show_survey();
}else{
//alert("start timer with bal" + ((TimetoPopup-timeDiff)/1000));
setTimeout("show_survey()",TimetoPopup-timeDiff);
}
}
}
function show_survey(){
//reset timer when popclosed
var enter_pcom=new Date();
clockStart=enter_pcom.getTime();
SetCookie('EnterPcom', clockStart);
var loc=window.location.toString();
var channelAry = new Array();
channelAry=loc.split('/');
//alert(channelAry[3]);
channel=channelAry[3];
var donesvy=get_cookie("DoneSurvey");
if (donesvy!='Y')
{
var winl = (screen.width-369)/2;
var wint = (screen.height-345)/2;
//var w_prop='left='+winl+',top='+wint+',width=369,height=400,location=no, menubar=no, resizable=no, scrollbars=no, status=no, titlebar=no, toolbar=no';
if (window.showModalDialog) {
//alert("IE open");
//window.showModalDialog('/includes/PopupSurvey/exit_survey.asp?channel='+channel,'popup survey','dialogWidth:345px;dialogHeight:350px;location:no;center:yes;help:no;status:no;scroll:no;');
w=window.open('/includes/PopupSurvey/site_survey.asp?channel='+channel,'_blank','left='+winl+',top='+wint+',height=350,width=345,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no ,modal=yes');
w.focus();
} else {
w=window.open('/includes/PopupSurvey/site_survey.asp?channel='+channel,'_blank','left='+winl+',top='+wint+',height=300,width=345,toolbar=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no ,modal=yes');
w.focus();
}
}else{
//no pop up exit
}
}
function get_cookie(Name) {
var search = Name + "="
var returnvalue = "";
if (document.cookie.length > 0) {
offset = document.cookie.indexOf(search)
if (offset != -1) { // if cookie exists
offset += search.length
// set index of beginning of value
end = document.cookie.indexOf(";", offset);
// set index of end of cookie value
if (end == -1)
end = document.cookie.length;
returnvalue=unescape(document.cookie.substring(offset, end))
}
}
return returnvalue;
}
function SetCookie (name, value) {
var argv = SetCookie.arguments;
var argc = SetCookie.arguments.length;
var expires = (argc > 2) ? argv[2] : null;
var path = "/";
//var path = (argc > 3) ? argv[3] : null;
//var domain = "";//(argc > 4) ? argv[4] : null;
//var secure = (argc > 5) ? argv[5] : false;
//alert (path);
//alert (domain);
//alert (expires);
document.cookie = name + "=" + escape (value) +
((expires == null) ? "" : ("; expires=" + expires.toGMTString())) +
((path == null) ? "" : ("; path=" + path));// +
//((domain == null) ? "" : ("; domain=" + domain)) ;
//((secure == true) ? "; secure" : "");
}
I tried a link from yahoo360 alerts and it said You are trying to open a binary file, would you like to save it? when all it is is a link that's supposed to take me to a new message in my account.
Last edited by mbvpixies78; 12-24-2007 at 04:47 PM.
You do not have to have PHP installed in your machine to view PHP scripts which reside on a server. PHP is a server side scripting language and gets parsed in the server with the output sent to the browser.
Search for prefs.js file in the thunderbird directory ( should be /home/username/.mozilla/moziall-thunderbird )
Search for prefs.js file in the thunderbird directory ( should be /home/username/.mozilla/moziall-thunderbird )
What does the following setting have ?[/QUOTE]
I searched for prefs.js and of the many entries that came up, one was located at home/username/.thunderbird/zoj2mmv8.default/ and it didn't have an http entry, only an https:
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.