paypal php 对接
项目需要要在php中使用paypal支付。
先吐槽下paypal,以前做过国内的一些支付接口,有些经验。想到的是直接找paypal客服要接口文档。
尼玛加paypal客服QQ 不在线。几天如此。这么大的支付居然没技术支持,真不能理解。文档后面还是在官网7找8找才找到了。
正文:
首先要在sandbox环境申请主帐号。连接:https://developer.paypal.com/
申请后用主帐号登录申请卖家以及买家帐号。然后进行一些设置。
注意:如果买家是国外的,那么创建买家帐号的时候就要设置所在国家。这样在支付页面才会以该国家的语言显示界面。
申请帐号以及设置问题请参考文档 连接:https://www.paypal-biz.com/development/documentation/PayPal_Sandbox_Guide_CN_V2.0.pdf
支付过程首先第一步是提交表单给paypal 当然post方式。
<span style="color: #0000ff;"><span style="color: #800000;">form </span><span style="color: #ff0000;">id</span><span style="color: #0000ff;">="form_starPay"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="form_starPay"</span><span style="color: #ff0000;"> action</span><span style="color: #0000ff;">="https://www.sandbox.paypal.com/cgi-bin/webscr"</span><span style="color: #ff0000;"> method</span><span style="color: #0000ff;">="post"</span><span style="color: #0000ff;">></span> <span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="cmd"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="_xclick"</span><span style="color: #0000ff;">></span> //告诉paypal该表单是立即购买 <span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="business"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="XXXXXX@XXXXX.com"</span><span style="color: #0000ff;">></span> //卖家帐号 也就是收钱的帐号 <span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="item_name"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="name"</span><span style="color: #0000ff;">></span> //商品名称 <span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="amount"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="10000"</span><span style="color: #0000ff;">></span> //价格 <span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="currency_code"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="JPY"</span><span style="color: #0000ff;">></span> //币种 <span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="return"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="http://localhost/frontend/pay/PDT_order"</span><span style="color: #0000ff;">> //支付成功后网页跳转地址</span> <span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="notify_url"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="http://localhost/frontend/pay/IPN_Order"</span><span style="color: #0000ff;">> </span>//支付成功后paypal后台发送订单通知地址<br><span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="invoice"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">=""</span><span style="color: #0000ff;">> //自定义订单号 paypal原样返回<br></span><span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="custom"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">=""</span><span style="color: #0000ff;">></span><span style="line-height: 1.5;"> // 自定义变量 paypal原样返回<br></span><span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">type</span><span style="color: #0000ff;">="hidden"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="lc"</span><span style="color: #ff0000;"> value</span><span style="color: #0000ff;">="JP"</span><span style="color: #0000ff;">></span><span style="line-height: 1.5;"> //支付页面语言设置<br></span><span style="color: #0000ff;"><span style="color: #800000;">input </span><span style="color: #ff0000;">style</span><span style="color: #0000ff;">="visibility:hidden"</span><span style="color: #ff0000;"> type</span><span style="color: #0000ff;">="image"</span><span style="color: #ff0000;"> src</span><span style="color: #0000ff;">=" https://www.paypal.com/en_US/i/btn/btn_buynow_LG.gif "</span><span style="color: #ff0000;"> border</span><span style="color: #0000ff;">="0"</span><span style="color: #ff0000;"> name</span><span style="color: #0000ff;">="submit"</span><span style="color: #ff0000;"> alt</span><span style="color: #0000ff;">=" PayPal - The safer, easier way to pay online"</span><span style="color: #0000ff;">>//支付按钮<br><br></span><span style="color: #0000ff;"></span><span style="color: #800000;">form</span><span style="color: #0000ff;">></span></span></span></span></span></span></span></span></span></span></span></span></span>
当支付成功后 paypal就会跳转到我们设置的 “return” 地址,会带上一个流水号 我们get方式就可以取到值。流水号键名 “tx”。
拿到流水号然后加上身份标识跟cmd变量就可以到paypal请求刚才支付的订单的交易内容。
例如:cmd=_notify-synch&tx=123sflsfjlw12&tx_token=fsfljvw3lwejloj43jfvdflf2
cmd=_notify-synch是告诉paypal你要做什么,这里是查询订单交易。
tx_token值要在paypal后台取,刚才注册帐号的时候要开通pdt功能才行。
这个过程paypal称为:PDT (Payment Data Transfer 付款数据传输)。
我们接收到返回的一些数据后就可以进行一些支付后的操作,比如发金币,发货等等。
pdt 详细的返回参数最后给出文档。
代码:
<span style="color: #000000;">php </span><span style="color: #008000;">//</span><span style="color: #008000;">获取 PayPal 交易流水号 tx </span> <span style="color: #800080;">$tx_token</span> = <span style="color: #800080;">$_GET</span>['tx'<span style="color: #000000;">]; </span><span style="color: #008000;">//</span><span style="color: #008000;">定义您的身份标记 </span> <span style="color: #800080;">$auth_token</span> = "CHANGE-TO-YOUR-TOKEN"<span style="color: #000000;">; </span><span style="color: #008000;">//</span><span style="color: #008000;">形成验证字符串 </span> <span style="color: #800080;">$req</span> = " cmd=_notify-synch&tx=<span style="color: #800080;">$tx_token</span>&at=<span style="color: #800080;">$auth_token</span>"<span style="color: #000000;">; </span><span style="color: #008000;">//</span><span style="color: #008000;">将交易流水号及身份标记返回 PayPal 验证 </span> <span style="color: #800080;">$header</span> .= "POST /cgi-bin/webscr HTTP/1.0\r\n"<span style="color: #000000;">; </span><span style="color: #800080;">$header</span> .= "Content-Type: application/x-www-form-urlencoded\r\n"<span style="color: #000000;">; </span><span style="color: #800080;">$header</span> .= "Content-Length: " . <span style="color: #008080;">strlen</span>(<span style="color: #800080;">$req</span>) . "\r\n\r\n"<span style="color: #000000;">; </span><span style="color: #800080;">$fp</span> = <span style="color: #008080;">fsockopen</span> ('www.paypal.com', 80, <span style="color: #800080;">$errno</span>, <span style="color: #800080;">$errstr</span>, 30<span style="color: #000000;">); </span><span style="color: #0000ff;">if</span> (!<span style="color: #800080;">$fp</span><span style="color: #000000;">) { </span><span style="color: #008000;">//</span><span style="color: #008000;"> HTTP ERROR </span> } <span style="color: #0000ff;">else</span><span style="color: #000000;"> { </span><span style="color: #008080;">fputs</span> (<span style="color: #800080;">$fp</span>, <span style="color: #800080;">$header</span> . <span style="color: #800080;">$req</span><span style="color: #000000;">); </span><span style="color: #008000;">//</span><span style="color: #008000;">获取返回数据 </span> <span style="color: #800080;">$res</span> = ''<span style="color: #000000;">; </span><span style="color: #800080;">$headerdone</span> = <span style="color: #0000ff;">false</span><span style="color: #000000;">; </span><span style="color: #0000ff;">while</span> (!<span style="color: #008080;">feof</span>(<span style="color: #800080;">$fp</span><span style="color: #000000;">)) { </span><span style="color: #800080;">$line</span> = <span style="color: #008080;">fgets</span> (<span style="color: #800080;">$fp</span>, 1024<span style="color: #000000;">); </span><span style="color: #0000ff;">if</span> (<span style="color: #008080;">strcmp</span>(<span style="color: #800080;">$line</span>, "\r\n") == 0<span style="color: #000000;">) { </span><span style="color: #008000;">//</span><span style="color: #008000;">获取头 </span> <span style="color: #800080;">$headerdone</span> = <span style="color: #0000ff;">true</span><span style="color: #000000;">; }</span><span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> (<span style="color: #800080;">$headerdone</span><span style="color: #000000;">){ </span><span style="color: #008000;">//</span><span style="color: #008000;">获取主体内容 </span> <span style="color: #800080;">$res</span> .= <span style="color: #800080;">$line</span><span style="color: #000000;">; } } </span><span style="color: #008000;">//</span><span style="color: #008000;">解析获取内容 </span> <span style="color: #800080;">$lines</span> = <span style="color: #008080;">explode</span>("\n", <span style="color: #800080;">$res</span><span style="color: #000000;">); </span><span style="color: #800080;">$keyarray</span> = <span style="color: #0000ff;">array</span><span style="color: #000000;">(); </span><span style="color: #0000ff;">if</span> (<span style="color: #008080;">strcmp</span> (<span style="color: #800080;">$lines</span>[0], "SUCCESS") == 0<span style="color: #000000;">) { </span><span style="color: #0000ff;">for</span> (<span style="color: #800080;">$i</span>=1; <span style="color: #800080;">$i</span>count(<span style="color: #800080;">$lines</span>);<span style="color: #800080;">$i</span>++<span style="color: #000000;">){ </span><span style="color: #0000ff;">list</span>(<span style="color: #800080;">$key</span>,<span style="color: #800080;">$val</span>) = <span style="color: #008080;">explode</span>("=", <span style="color: #800080;">$lines</span>[<span style="color: #800080;">$i</span><span style="color: #000000;">]); </span><span style="color: #800080;">$keyarray</span>[<span style="color: #008080;">urldecode</span>(<span style="color: #800080;">$key</span>)] = <span style="color: #008080;">urldecode</span>(<span style="color: #800080;">$val</span><span style="color: #000000;">); } </span><span style="color: #008000;">//</span><span style="color: #008000;">检查交易付款状态 payment_status 是否为 „Completed‟ //检查交易流水号 txn_id 是否已经被处理过 //检查接收 EMAIL receiver_email 是否为您的 PayPal 中已经注册的 EMAIL //检查金额 mc_gross 是否正确 //…… //处理此次付款明细 //该付款明细所有变量可参考: //https://www.paypal.com/IntegrationCenter/ic_ipn-pdt-variable-reference.html </span> <span style="color: #800080;">$name</span> = <span style="color: #800080;">$keyarray</span>['first_name'] . ' ' . <span style="color: #800080;">$keyarray</span>['last_name'<span style="color: #000000;">]; </span><span style="color: #800080;">$itemname</span> = <span style="color: #800080;">$keyarray</span>['item_name'<span style="color: #000000;">]; </span><span style="color: #800080;">$amount</span> = <span style="color: #800080;">$keyarray</span>['mc_gross'<span style="color: #000000;">]; </span><span style="color: #0000ff;">echo</span> ("<p></p><h3 id="Thank-you-for-you-purchase">Thank you for you purchase!</h3>"<span style="color: #000000;">); </span><span style="color: #0000ff;">echo</span> ("<b>Payment Details:</b><br>\n"<span style="color: #000000;">); </span><span style="color: #0000ff;">echo</span> ("
为了防止用户关掉浏览器,订单通知不到的情况。paypal还提供了一种通知方式:IPN (Instant Payment Notification 即时付款通知);
IPN 是在后台进行http请求通知。
当开通了ipn功能,并且订单状态发生改变的时候,paypal会主动请求我们支付表单中变量“notify_url”提供的地址。
我们在接收到paypal请求后要拿到所有的数据。
然后用 “cmd=_notify-validate”加上刚才的数据,http发送给paypal进行验证,以防请求是伪造的。
代码:
<span style="color: #000000;">php </span><span style="color: #008000;">//</span><span style="color: #008000;">从 PayPal 出读取 POST 信息同时添加变量„cmd‟ </span> <span style="color: #800080;">$req</span> = 'cmd=_notify-validate'<span style="color: #000000;">; </span><span style="color: #0000ff;">foreach</span> (<span style="color: #800080;">$_POST</span> <span style="color: #0000ff;">as</span> <span style="color: #800080;">$key</span> => <span style="color: #800080;">$value</span><span style="color: #000000;">) { </span><span style="color: #800080;">$value</span> = <span style="color: #008080;">urlencode</span>(<span style="color: #008080;">stripslashes</span>(<span style="color: #800080;">$value</span><span style="color: #000000;">)); </span><span style="color: #800080;">$req</span> .= "&<span style="color: #800080;">$key</span>=<span style="color: #800080;">$value</span>"<span style="color: #000000;">; } </span><span style="color: #008000;">//</span><span style="color: #008000;">建议在此将接受到的信息记录到日志文件中以确认是否收到 IPN 信息 //将信息 POST 回给 PayPal 进行验证 </span> <span style="color: #800080;">$header</span> .= "POST /cgi-bin/webscr HTTP/1.0\r\n"<span style="color: #000000;">; </span><span style="color: #800080;">$header</span> .= "Content-Type:application/x-www-form-urlencoded\r\n"<span style="color: #000000;">; </span><span style="color: #800080;">$header</span> .= "Content-Length:" . <span style="color: #008080;">strlen</span>(<span style="color: #800080;">$req</span>) ."\r\n\r\n"<span style="color: #000000;">; </span><span style="color: #008000;">//</span><span style="color: #008000;">在 Sandbox 情况下,设置: //$fp = fsockopen(„www.sandbox.paypal.com‟,80,$errno,$errstr,30); </span> <span style="color: #800080;">$fp</span> = <span style="color: #008080;">fsockopen</span> ('www.paypal.com', 80, <span style="color: #800080;">$errno</span>, <span style="color: #800080;">$errstr</span>, 30<span style="color: #000000;">); </span><span style="color: #008000;">//</span><span style="color: #008000;">将 POST 变量记录在本地变量中 //该付款明细所有变量可参考: //https://www.paypal.com/IntegrationCenter/ic_ipn-pdt-variable-reference.html </span> <span style="color: #800080;">$item_name</span> = <span style="color: #800080;">$_POST</span>['item_name'<span style="color: #000000;">]; </span><span style="color: #800080;">$item_number</span> = <span style="color: #800080;">$_POST</span>['item_number'<span style="color: #000000;">]; </span><span style="color: #800080;">$payment_status</span> = <span style="color: #800080;">$_POST</span>['payment_status'<span style="color: #000000;">]; </span><span style="color: #800080;">$payment_amount</span> = <span style="color: #800080;">$_POST</span>['mc_gross'<span style="color: #000000;">]; </span><span style="color: #800080;">$payment_currency</span> = <span style="color: #800080;">$_POST</span>['mc_currency'<span style="color: #000000;">]; </span><span style="color: #800080;">$txn_id</span> = <span style="color: #800080;">$_POST</span>['txn_id'<span style="color: #000000;">]; </span><span style="color: #800080;">$receiver_email</span> = <span style="color: #800080;">$_POST</span>['receiver_email'<span style="color: #000000;">]; </span><span style="color: #800080;">$payer_email</span> = <span style="color: #800080;">$_POST</span>['payer_email'<span style="color: #000000;">]; </span><span style="color: #008000;">//</span><span style="color: #008000;">… //判断回复 POST 是否创建成功 </span> <span style="color: #0000ff;">if</span> (!<span style="color: #800080;">$fp</span><span style="color: #000000;">) { </span><span style="color: #008000;">//</span><span style="color: #008000;">HTTP 错误 </span> }<span style="color: #0000ff;">else</span><span style="color: #000000;"> { </span><span style="color: #008000;">//</span><span style="color: #008000;">将回复 POST 信息写入 SOCKET 端口 </span> <span style="color: #008080;">fputs</span> (<span style="color: #800080;">$fp</span>, <span style="color: #800080;">$header</span> .<span style="color: #800080;">$req</span><span style="color: #000000;">); </span><span style="color: #008000;">//</span><span style="color: #008000;">开始接受 PayPal 对回复 POST 信息的认证信息 </span> <span style="color: #0000ff;">while</span> (!<span style="color: #008080;">feof</span>(<span style="color: #800080;">$fp</span><span style="color: #000000;">)) { </span><span style="color: #800080;">$res</span> = <span style="color: #008080;">fgets</span> (<span style="color: #800080;">$fp</span>, 1024<span style="color: #000000;">); </span><span style="color: #008000;">//</span><span style="color: #008000;">已经通过认证 </span> <span style="color: #0000ff;">if</span> (<span style="color: #008080;">strcmp</span> (<span style="color: #800080;">$res</span>, "VERIFIED") == 0<span style="color: #000000;">) { </span><span style="color: #008000;">//</span><span style="color: #008000;">检查付款状态 //检查 txn_id 是否已经处理过 //检查 receiver_email 是否是您的 PayPal 账户中的 EMAIL 地址 //检查付款金额和货币单位是否正确 //处理这次付款,包括写数据库 </span> }<span style="color: #0000ff;">else</span> <span style="color: #0000ff;">if</span> (<span style="color: #008080;">strcmp</span> (<span style="color: #800080;">$res</span>, "INVALID") == 0<span style="color: #000000;">) { </span><span style="color: #008000;">//</span><span style="color: #008000;">未通过认证,有可能是编码错误或非法的 POST 信息 </span> <span style="color: #000000;">} } </span><span style="color: #008080;">fclose</span> (<span style="color: #800080;">$fp</span><span style="color: #000000;">); } </span>?>
接口对接就这样好了,搞清楚了流程很简单。
如果币种不是paypal默认的,在订单支付后订单状态一直是pending, 用卖家帐号登录在订单状态哪里点击接收,paypal就会自动设置接收该币种功能。
技术文档地址:https://www.paypal-biz.com/developer/documentation/2134.html

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

According to news from this site on June 24, at the keynote speech of the HDC2024 Huawei Developer Conference on June 21, Gong Ti, President of Huawei Terminal BG Software Department, officially announced Huawei’s self-developed Cangjie programming language. This language has been developed for 5 years and is now available for developer preview. Huawei's official developer website has now launched the official introductory tutorial video of Cangjie programming language to facilitate developers to get started and understand it. This tutorial will take users to experience Cangjie, learn Cangjie, and apply Cangjie, including using Cangjie language to estimate pi, calculate the stem and branch rules for each month of 2024, see N ways of expressing binary trees in Cangjie language, and use enumeration types to implement Algebraic calculations, signal system simulation using interfaces and extensions, and new syntax using Cangjie macros, etc. This site has tutorial access address: ht

This site reported on June 21 that at the HDC2024 Huawei Developer Conference this afternoon, Gong Ti, President of Huawei Terminal BG Software Department, officially announced Huawei’s self-developed Cangjie programming language and released a developer preview version of HarmonyOSNEXT Cangjie language. This is the first time Huawei has publicly released the Cangjie programming language. Gong Ti said: "In 2019, the Cangjie programming language project was born at Huawei. After 5 years of R&D accumulation and heavy R&D investment, it finally meets global developers today. Cangjie programming language integrates modern language features, comprehensive compilation optimization and Runtime implementation and out-of-the-box IDE tool chain support create a friendly development experience and excellent program performance for developers. "According to reports, Cangjie programming language is an all-scenario intelligence tool.

According to news from this site on June 21, Huawei’s self-developed Cangjie programming language was officially unveiled today, and the official announced the launch of HarmonyOSNEXT Cangjie language developer preview version Beta recruitment. This upgrade is an early adopter upgrade to the developer preview version, which provides Cangjie language SDK, developer guides and related DevEcoStudio plug-ins for developers to use Cangjie language to develop, debug and run HarmonyOSNext applications. Registration period: June 21, 2024 - October 21, 2024 Application requirements: This HarmonyOSNEXT Cangjie Language Developer Preview Beta recruitment event is only open to the following developers: 1) Real names have been completed in the Huawei Developer Alliance Certification; 2) Complete H

According to news from this site on June 22, Huawei yesterday introduced Huawei’s self-developed programming language-Cangjie to developers around the world. This is the first public appearance of Cangjie programming language. According to inquiries on this site, Tianjin University and Beijing University of Aeronautics and Astronautics were deeply involved in the research and development of Huawei’s “Cangjie”. Tianjin University: Cangjie Programming Language Compiler The software engineering team of the Department of Intelligence and Computing of Tianjin University joined hands with the Huawei Cangjie team to deeply participate in the quality assurance research of the Cangjie programming language compiler. According to reports, the Cangjie compiler is the basic software that is symbiotic with the Cangjie programming language. In the preparatory stage of the Cangjie programming language, a high-quality compiler that matches it became one of the core goals. As the Cangjie programming language evolves, the Cangjie compiler is constantly being upgraded and improved. In the past five years, Tianjin University

According to news from this site on June 21, before the HDC2024 Huawei Developer Conference, Huawei’s self-developed Cangjie programming language was officially unveiled, and the Cangjie official website is now online. The official website introduction shows that Cangjie programming language is a new generation programming language for all-scenario intelligence, focusing on "native intelligence, natural all-scenarios, high performance, and strong security." Integrate into the Hongmeng ecosystem to provide developers with a good programming experience. The official website attached to this site introduces as follows: Native intelligent programming framework embedded with AgentDSL, organic integration of natural language & programming language; multi-Agent collaboration, simplified symbolic expression, free combination of patterns, supporting the development of various intelligent applications. Innately lightweight and scalable runtime for all scenes, modular layered design, no matter how small the memory is, it can be accommodated; all-scenario domain expansion

According to news on June 21, this afternoon, Huawei Developer Conference 2024 will be officially opened. "Pure-blood Hongmeng" Harmony OS NEXT is naturally a top priority. According to the plan previously revealed by Yu Chengdong, the public beta may be officially announced this afternoon, and ordinary consumers can also try out "pure-blood Harmony". According to reports, the first batch of supported mobile phones are the Mate60 series and Pura70 series. It is worth noting that as a "pure-blooded Hongmeng", HarmonyOSNEXT has removed the traditional Linux kernel and AOSP Android open source code and developed the entire stack in-house. According to the latest report from Sina Technology, Huawei will also complete the last link of Hongmeng Ecosystem and expand its presence in the world.

Since the launch of ChatGLM-6B on March 14, 2023, the GLM series models have received widespread attention and recognition. Especially after ChatGLM3-6B was open sourced, developers are full of expectations for the fourth-generation model launched by Zhipu AI. This expectation has finally been fully satisfied with the release of GLM-4-9B. The birth of GLM-4-9B In order to give small models (10B and below) more powerful capabilities, the GLM technical team launched this new fourth-generation GLM series open source model: GLM-4-9B after nearly half a year of exploration. This model greatly compresses the model size while ensuring accuracy, and has faster inference speed and higher efficiency. The GLM technical team’s exploration has not

According to news from this site on June 21, Huawei’s self-developed Cangjie programming language was officially unveiled today, and the HarmonyOSNEXT Cangjie language developer preview version Beta recruitment was launched. The Cangjie Programming Language Q&A page on Huawei's official website shows that Cangjie Programming Language is a next-generation application programming language oriented to all-scenario intelligence. It focuses on native intelligence, natural all-scenarios, high performance and strong security. It is combined with Hongmeng system to provide good programming. experience. For different business scenarios, Hongmeng Ecosystem provides application developers with multi-language hybrid development capabilities such as Cangjie and ArkTS. Cangjie and ArkTS develop together and form complementary advantages in the Hongmeng ecosystem. Cangjie is more suitable for business scenarios with high performance and high concurrency requirements. The goal of Cangjie programming language is to create Hongmeng applications that can perform tasks concurrently.
