Changeset 9260


Ignore:
Timestamp:
Feb 17, 2011, 1:15:21 PM (13 years ago)
Author:
ddtddt
Message:

[extensions] - AddInfo

Location:
extensions/AddInfo
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/AddInfo/admin/admin.php

    r9259 r9260  
    9898      'VALUE' => $idimg,
    9999          'VALUEN' => $chnameimg,
    100       'CONTENT' => $info1,
    101       'CONTENT2' => $info2,
    102           'CONTENT3' => $info3,
     100      'CONTENT' => htmlspecialchars($info1),
     101      'CONTENT2' => htmlspecialchars($info2),
     102          'CONTENT3' => htmlspecialchars($info3),
    103103      'SELECTED' => $selected3
    104104      ));
  • extensions/AddInfo/initadmin.php

    r9155 r9260  
    8080    array(
    8181      //'AIVALUE' => $idaddinfo,
    82       'AICONTENT' => $info1,
    83       'AICONTENT2' => $info2,
    84           'AICONTENT3' => $info3,
     82      'AICONTENT' => htmlspecialchars($info1),
     83      'AICONTENT2' => htmlspecialchars($info2),
     84          'AICONTENT3' => htmlspecialchars($info3),
    8585      ));
    8686 }
     
    9898    pwg_query($q);
    9999       
    100         $template->assign(
     100 $query = '
     101select id,info1,info2,info3
     102  FROM ' . ADDINFO_TABLE . '
     103  WHERE id = '.$_GET['image_id'].'
     104  ;';
     105$result = pwg_query($query);
     106$row = mysql_fetch_array($result);
     107$idaddinfo=$row['id'];
     108$info1=$row['info1'];
     109$info2=$row['info2'];
     110$info3=$row['info3'];
     111
     112        global $template, $prefixeTable;
     113
     114$template->assign(
    101115    array(
    102       'AICONTENT' => $_POST['inser'],
    103       'AICONTENT2' => $_POST['inser2'],
    104           'AICONTENT3' => $_POST['inser3'],
     116      //'AIVALUE' => $idaddinfo,
     117      'AICONTENT' => htmlspecialchars($info1),
     118      'AICONTENT2' => htmlspecialchars($info2),
     119          'AICONTENT3' => htmlspecialchars($info3),
    105120      ));
    106121 }       
Note: See TracChangeset for help on using the changeset viewer.