Record
(Jump from page A to page B, and take the value of the page B to the display on page A)
Let's raise a chestnut first;)
This is page A
This is page B
Turn to page B by clicking on the add log on page A, and transmit the log content added to the page B to the red box position on the A page
First quote js, I have a cither here an plug -in of OpenPage.js itself
// This is to fill the JSON data returned to the logging log in the log (data) {// After successful, the data returned by the log data returned to the log in the log is placed on a page A. stringify (data); var remark = data.body.remark; // Content var addtimestr = data.body.addtimestr; VAR HTML = '<DIV Class = AccessLog> <Div class = Val-Lo g> ' + Remark +' </div> <div class = time-log> ' + addimestr +' </div> </div> '; $ (. js_nojilu) .hide (); $ (. js_rizhi) .prepend (html)} <div} Class = DetailSS-BTN JS_OPENPAGE DATA- URL=/oacustomer/[email protected]> Add logs </div> Configure head in public js(Detailed app head configuration instructions ----------- APP configuration page head head)
A head/oacomomer/CustomerDetail: {title: customer details, head: [{ForeImage: iconback, eventstring: gjj://close.page/1? Jc5wywdpbmcuc2vhc2vhc mnokck7}], Headrid: [{ForeImage: icondrop, Type: DropdownList, MENUS: [{iconimage: iconcontentchange, Alpha: 100, Text: modify customer information, textSize: 16, TextColor: 000000, backColor: FFFFFFF, EVENTRING: MODIF ication ()},],}]}, B. Head/OACUSTOMER/Addlogview: {Title: Add customer log, headrid: [{text: submission, eventstring: submit ()}]} // The head configured in js is placed on page B // Submit a function submit () {var mes = $ (form). Validtor (); if (mes) {$ .dialog.OpendialogString (MES); Return false; dlog; $ .ajax ({Type : post, url: url, data: $ (form) .Serialize (), datatype: json, beForesend: function () {}, error: function () {$ .dialog.opndialogString, please try it out); }, SUCCESS: Function (data) {if (data.dictjsonstatus == 200) {// Fill the JSON data returned to the logging log into customer details $ .zprotocol ({type: close.page, PATH: /1, SUCCESS : 'Dunnage (' + json.stringify (data) + ')'});} Else {$ .dialog.opndialogString (data.msg);}} // Page content <FORM =/OACUSTOMER/SUBMI taddlog > // Action (submitaddlog) <! ---------------> <input type = hidden [email protected] name = fkoacusomler/> <div class = remark > <p> <i style = color:#f00>*</i> Remarks: </p> <p> <textarea Placeholder = Please fill in the application statement (must) class = js_inputbox name = Remark Data-Tipname = Remarks message data-value = '{required: true}'> </textarea> </p> </form> </form>After taking the data, you will close a page, that is, the page B, and return to the previous page, which is a page A. Finally, the data showed at the red box on the A page.
The above is the web front -end page jump and value introduced by Xiaobian. I hope it will be helpful to everyone. If you have any questions, please leave me a message. Xiaobian will reply to everyone in time. Thank you very much for your support for the VEVB Wulin website!