1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- // Initialize your app
- var myApp = new Framework7({
- animateNavBackIcon: true,
- modalButtonOk: '确定',
- modalButtonCancel: '取消'
- });
- // Export selectors engine
- var $$ = Dom7;
- var maxPages = 0;
- // Add view
- var mainView = myApp.addView('.view-main', {
- // Because we use fixed-through navbar we can enable dynamic navbar
- dynamicNavbar: true
- });
- var html = '', id = 0;
- function getURLCode(){
- var search = location.search.length > 0 ? location.search.substring(1) : '',
- args = {},
- items = search.length ? search.split('&') : [],
- item = null,
- name = null,
- value = null,
- i = 0,
- len = items.length,
- data = '';
- for (i = 0; i < len; i++) {
- item = items[i].split('=');
- name = decodeURIComponent(item[0]);
- value = decodeURIComponent(item[1]);
- if (item.length) {
- args[name] = value
- }
- }
- return args;
- }
- id = getURLCode()['id'];
- console.log(id);
- $$.post('/user/information/getinformationcontentbyid', { id: id}, function (data) {
- res = JSON.parse(data);
- if (res.errno == 0) {
- // console.log(res);
- document.title = res.rst.title;
- $$('#content .title').html(res.rst.title);
- if(res.rst.content.indexOf("bwadmin.quyaqu.comhttp:") != -1){
- res.rst.content = res.rst.content.replace(/bwadmin.quyaqu.comhttp:/g, '');
- }
- $$('#content .container').html(res.rst.content)
- }
- });
|