TB extension should have a download now link instead of install now

RESOLVED DUPLICATE of bug 247200

Status

addons.mozilla.org Graveyard
Public Pages
RESOLVED DUPLICATE of bug 247200
14 years ago
2 years ago

People

(Reporter: Jaap A. Haitsma, Assigned: wolf)

Tracking

Details

(Reporter)

Description

14 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7) Gecko/20040625 Firefox/0.9
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7) Gecko/20040625 Firefox/0.9

If you click on the install now link of TB extension it will try to install the
extension in FF, which consequently fails. The user should download the
extension so Download now would be better instead of install now. With some php
code you can make sure that the file gets downloaded instead of installed. This
is the php code  I use:
----------
<?php

$completeFilePath = substr($_SERVER['PATH_INFO'], 1);

if ( stristr($completeFilePath, 'tp://') ) {

$fileName = basename($completeFilePath);

header('Cache-Control: no-cache, must-revalidate');
header('Pragma: no-cache');

// C-D: attachment; ?
header("Content-type: application/octet-stream\nContent-Disposition: inline;
filename=\"".$fileName."\"");

$fd=fopen($completeFilePath,'r');

fpassthru($fd);

} else {

header('Location: /');

}

?>

-----

Then you can make sure that the extension is downloaded by using the following link.

http://dictionarysearch.mozdev.org/download.php/http://downloads.mozdev.org/dictionarysearch/dictionarysearch_0.6.1.xpi

Reproducible: Always
Steps to Reproduce:
(Assignee)

Comment 1

14 years ago
Thanks for the PHP code here, but it won't work with update.. the
update.mozilla.org server doesn't have the files on it, it redirects to the
ftp.m.o mirrors.

This bug is also a duplicate.. Marking as such.

*** This bug has been marked as a duplicate of 247200 ***
Status: UNCONFIRMED → RESOLVED
Last Resolved: 14 years ago
Resolution: --- → DUPLICATE
(Assignee)

Updated

13 years ago
Component: Update → Web Site
Product: mozilla.org → Update
Version: other → unspecified
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.