検索
ホームページphp教程php手册How to install/setup latest version of PHP 5.5 on

Please note: This works fine. But this package will also upgrade your apache to version 2.4 which has different config files than apache 2.2 and even deletes stuff, like?/etc/apache2/sites-available/defaultwhen upgrading. This may result i

Please note: This works fine. But this package will also upgrade your apache to version 2.4 which has different config files than apache 2.2 and even deletes stuff, like?/etc/apache2/sites-available/defaultwhen upgrading. This may result in a loss of your apache settings (vhost, mod_rewrite stuff etc.). Be aware of that ! This shit cost me a full weekend. This affects only upgrades, not fresh installs for sure.?Update:?This is a known bug (more here), I’ll keep this post updated…

How to install

There’s an excellent and (usually) hassle-free method to install the latest version of PHP5 (which is 5.5.3 when i’m writing this) with 3 simple bash commands:

1. Add this package-repository to your system. If Ubuntu says that you need to download a key first, then follow the instructions given in the notice.

sudo add-apt-repository ppa:ondrej/php5

If you get an error message now, then please do an update first and install the python-software-properties, that need to be necessary to add a package repository:

sudo apt-get update
sudo apt-get install python-software-properties

2. Update

sudo apt-get update

3. Install PHP

sudo apt-get install php5
更新过程中可能会出现The package openfire needs to be reinstalled, but I can't find an archive for it的错误。
使用命令将openfire卸载掉:?dpkg --remove --force-remove-reinstreq openfire

Check the installed version of PHP via

php5 -v

Please note: The ondrej/php5 repository (which is used here) provides the very latest version of PHP. Usually the new version of PHP is available a few days after it was been officially released. This is really cool and a big step forward as Ubuntu, Debian, CentOS etc. provide only very old versions by default.

To UPDATE from PHP 5.3 / 5.4 to PHP 5.5:

It’s also possible to update from any PHP version to the latest one with exactly the commands above. But, after doing

sudo apt-get install php5

you’ll have to restart the server with

sudo /etc/init.d/apache2 restart

or

sudo service apache2 restart

By the way, I’ve also written a tutorial on “How to setup latest version of PHP 5.5 on Debian Wheezy 7.0/7.1/7.2 (and how to fix the GPG key error)“, which is different from this here.

声明
この記事の内容はネチズンが自主的に寄稿したものであり、著作権は原著者に帰属します。このサイトは、それに相当する法的責任を負いません。盗作または侵害の疑いのあるコンテンツを見つけた場合は、admin@php.cn までご連絡ください。
在 Mac 上创建 Windows 11 USB 安装程序的 3 种简单方法在 Mac 上创建 Windows 11 USB 安装程序的 3 种简单方法May 13, 2023 pm 09:43 PM

Windows11引入了丰富的新功能以及全面改进的外观,更加强调统一性和效率。因此,今天的主题是如何在Mac上创建Windows11USB安装程序。执行Windows11的全新安装而不是升级,是在获取操作系统时产生最佳结果的方法。使用可在Windows11中启动的驱动器,您可以执行此任务。如果您使用的是WindowsPC,则为Windows11制作可引导CD是一个非常简单的过程。另一方面,如果您使用的是Mac,则该过程会稍微复杂一些。这篇文章将描述如何在不使用基

如何在新的 SSD 上安装 macOS如何在新的 SSD 上安装 macOSApr 13, 2023 pm 04:01 PM

如何使用 macOS Recovery 在新的 SSD 上安装 macOS在 2009 年之后生产的任何 Mac 上,都有一个内置的恢复系统。这允许您将 Mac 启动到恢复模式。在此模式下,您可以修复内部磁盘、从 Time Machine 备份恢复文件、获取在线帮助或重新安装 macOS。您必须能够连接到互联网才能使用这些工具。您可以使用 macOS 安装工具在计算机中安装的新 SSD 上安装 macOS。要使用 Internet Recovery 在 SSD 上安装 macOS:按照制造商针对

如何在 Windows 10 上使用命令提示符安装 PHP如何在 Windows 10 上使用命令提示符安装 PHPMay 08, 2023 pm 05:13 PM

使用命令提示符或PowerShell在Windows上安装PHP安装ChocolateyChoco包管理器我尝试了Windows默认包管理器Winget,但无法通过它安装PHP。因此,剩下的另一个最佳选择是使用流行的Chocolatey包管理器。但与Winget不同的是,Choco默认情况下不存在于我们的Windows系统中,因此我们需要在我们的系统上手动安装它。转到您的Windows10或11搜索框并键入CMD,出现时选择“以管理员身份运行”将给定的命令复制

setup在电脑上什么意思setup在电脑上什么意思Feb 23, 2023 pm 02:06 PM

setup在电脑上的意思就是“安装”;通常的安装文件夹中,若是有setup文件,则双击setup文件就能安装这个程序;安装就是按照一定的程序、规格把机械或器材固定在一定的位置上,也指按照一定的方法、规格把机械或器材等固定在一定的地方。

聊聊vue3中setup函数的返回值聊聊vue3中setup函数的返回值Aug 09, 2022 am 10:26 AM

setup是vue3中的一个新的配置项,值为一个函数,我们在组件中用到的数据、方法等等,都要配置在setup中。

怎么在Vue3中使用<script lang=“ts“ setup>语法糖怎么在Vue3中使用<script lang=“ts“ setup>语法糖May 16, 2023 pm 04:39 PM

迁移组件以下组件有两个道具(要显示的和一个标志)。基于这两个道具,计算模板中显示的小马图像的URL(通过另一个组件)。该组件还会在用户单击它时发出一个事件。PonyponyModelisRunningImageselectedPony.vue{{ponyModel.name}}import{computed,defineComponent,PropType}from'vue';importImagefrom'./Image.vue'

Vue3怎么使用setup语法糖拒绝写returnVue3怎么使用setup语法糖拒绝写returnMay 12, 2023 pm 06:34 PM

Vue3.2setup语法糖是在单文件组件(SFC)中使用组合式API的编译时语法糖解决Vue3.0中setup需要繁琐将声明的变量、函数以及import引入的内容通过return向外暴露,才能在使用的问题1.在使用中无需return声明的变量、函数以及import引入的内容,即可在使用语法糖//import引入的内容import{getToday}from'./utils'//变量constmsg='Hello!'//函数func

Vue3中的setup与自定义指令怎么使用Vue3中的setup与自定义指令怎么使用May 14, 2023 pm 05:01 PM

setup语法糖最大好处就是所有声明部分皆可直接使用,无需return出去注意:部分功能还不完善,如:name、render还需要单独加入script标签按compositionAPI方式编写//setup下还可以附加setup语法糖独有import{ref,reactive,toRefs}from'vue'consta=1;constnum=ref(99)//基本数据类型constuser=reactive({//引用数据类型age:11})//解构能获取响应式

See all articles

ホットAIツール

Undresser.AI Undress

Undresser.AI Undress

リアルなヌード写真を作成する AI 搭載アプリ

AI Clothes Remover

AI Clothes Remover

写真から衣服を削除するオンライン AI ツール。

Undress AI Tool

Undress AI Tool

脱衣画像を無料で

Clothoff.io

Clothoff.io

AI衣類リムーバー

AI Hentai Generator

AI Hentai Generator

AIヘンタイを無料で生成します。

ホットツール

ドリームウィーバー CS6

ドリームウィーバー CS6

ビジュアル Web 開発ツール

ゼンドスタジオ 13.0.1

ゼンドスタジオ 13.0.1

強力な PHP 統合開発環境

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Eclipse を SAP NetWeaver アプリケーション サーバーと統合します。

mPDF

mPDF

mPDF は、UTF-8 でエンコードされた HTML から PDF ファイルを生成できる PHP ライブラリです。オリジナルの作者である Ian Back は、Web サイトから「オンザフライ」で PDF ファイルを出力し、さまざまな言語を処理するために mPDF を作成しました。 HTML2FPDF などのオリジナルのスクリプトよりも遅く、Unicode フォントを使用すると生成されるファイルが大きくなりますが、CSS スタイルなどをサポートし、多くの機能強化が施されています。 RTL (アラビア語とヘブライ語) や CJK (中国語、日本語、韓国語) を含むほぼすべての言語をサポートします。ネストされたブロックレベル要素 (P、DIV など) をサポートします。

AtomエディタMac版ダウンロード

AtomエディタMac版ダウンロード

最も人気のあるオープンソースエディター