📄 add_info.asp
字号:
}
this.addItems = function(){
for (i=0;i<arguments.length;i=i+2){
this.addItem(arguments[i],arguments[i+1]);
}
}
this.getRenderedText = function(){
text = "<td><select name='"+this.name+"' id='"+this.name+"_"+this.area.name+"' onchange='HyperTextArea.getArea(\""+ this.area.name +"\").select(this,\""+this.cmd+"\");'>\n";
for (i=0;i<this.items.length;i++){
thisItem = this.items[i]
text = text + "<option value='"+thisItem.value+"'>"+thisItem.lable+"</option>\n";
}
text = text + "</select></td>";
return text;
}
}
function MenuItem(value,lable){
this.value = value;
this.lable = lable;
}
HyperTextArea.areas = new Array();
HyperTextArea.getArea = function(name){
return HyperTextArea.areas[name];
}
HyperTextArea.activeArea = null;
HyperTextArea.about = function(){
var area;
for(i in HyperTextArea.areas){
area = HyperTextArea.getArea(i);
break;
}
window.open(area.resourcePath + "about.html");
}
HyperTextArea.updateAllAreas = function(){
//iterate over all areas and call update
for(i in HyperTextArea.areas){
area = HyperTextArea.areas[i];
area.update();
}
}
HyperTextArea.forms = new Array();
function getOffsetTop(elm) {
var mOffsetTop = elm.offsetTop;
var mOffsetParent = elm.offsetParent;
while(mOffsetParent){
mOffsetTop += mOffsetParent.offsetTop;
mOffsetParent = mOffsetParent.offsetParent;
}
return mOffsetTop;
}
function getOffsetLeft(elm) {
var mOffsetLeft = elm.offsetLeft;
var mOffsetParent = elm.offsetParent;
while(mOffsetParent) {
mOffsetLeft += mOffsetParent.offsetLeft;
mOffsetParent = mOffsetParent.offsetParent;
}
return mOffsetLeft;
}
function kb_handler(evt, rte) {
//contributed by Anti Veeranna (thanks Anti!)
if (evt.ctrlKey) {
var key = String.fromCharCode(evt.charCode).toLowerCase();
var cmd = '';
switch (key) {
case 'b': cmd = "bold"; break;
case 'i': cmd = "italic"; break;
case 'u': cmd = "underline"; break;
};
if (cmd) {
evt.target.ownerDocument.execCommand(cmd,false,true);
// stop the event bubble
evt.preventDefault();
evt.stopPropagation();
}
}
}
function stripWordHTML(oldString) {
var newString = oldString;
//清理word,excel里面复制过来的table html垃圾代码
newString = newString.replace("x:str", "");
newString = newString.replace("border=0", "border=1");
newString = newString.replace(/<(\w[^>]*) style="([^"]*)"/gi, "<$1")
newString = newString.replace(/<\/?SPAN[^>]*>/gi, "" ); //Remove all SPAN tags
newString = newString.replace(/<(\w[^>]*) lang=([^ |>]*)([^>]*)/gi, "<$1$3") ;// Remove Lang attributes
newString = newString.replace(/<(\w[^>]*) class=([^ |>]*)([^>]*)/gi, "<$1$3");// Remove Class attributes
//newString = newString.replace(/'/g, "'");
//trim string
newString = trim(newString);
return newString;
}
function stripHTML(oldString) {
var newString = oldString.replace(/(<([^>]+)>)/ig,"");
//replace carriage returns and line feeds
newString = escape(newString)
newString = newString.replace("%0D%0A"," ");
newString = newString.replace("%0A"," ");
newString = newString.replace("%0D"," ");
newString = unescape(newString)
//trim string
newString = trim(newString);
return newString;
}
function trim(inputString) {
// Removes leading and trailing spaces from the passed string. Also removes
// consecutive spaces and replaces it with one space. If something besides
// a string is passed in (null, custom object, etc.) then return the input.
if (typeof inputString != "string") { return inputString; }
var retValue = inputString;
var ch = retValue.substring(0, 1);
while (ch == " ") { // Check for spaces at the beginning of the string
retValue = retValue.substring(1, retValue.length);
ch = retValue.substring(0, 1);
}
ch = retValue.substring(retValue.length-1, retValue.length);
while (ch == " ") { // Check for spaces at the end of the string
retValue = retValue.substring(0, retValue.length-1);
ch = retValue.substring(retValue.length-1, retValue.length);
}
while (retValue.indexOf(" ") != -1) { // Note that there are two spaces in the string - look for multiple spaces within the string
retValue = retValue.substring(0, retValue.indexOf(" ")) + retValue.substring(retValue.indexOf(" ")+1, retValue.length); // Again, there are two spaces in each of the strings
}
return retValue; // Return the trimmed string back to the user
}
function getPaletteAsString(){
hexArray = new Array("00","55","AA","FF");
out = "";
out2 = "";
line = ""
row = 1;
count = 1;
for(i=hexArray.length-1;i>=0;i--){
val0 = hexArray[i];
for(j=hexArray.length-1;j>=0;j--){
val1 = hexArray[j];
for(k=hexArray.length-1;k>=0;k--){
val2 = hexArray[k];
hexVal = val0+val1+val2;
line = line + "\n <td id='#"+hexVal+"' bgcolor='#"+hexVal+"' width='15' height='15' onmouseover='this.style.border=\"1px dotted white\"' onclick='area.setColor(this.id)'><img width='1' height='1'></td>";
if(count==1 || (row % 2) == 0){
if(((count - 1) % 8) == 0){
out = out + "\n<tr>";
row++
}
out = out + line;
if((count % 8) == 0){
out = out + "\n</tr>";
}
}else{
if(((count - 1) % 8) == 0){
out2 = out2 + "\n<tr>";
row++
}
out2 = out2 + line;
if((count % 8) == 0){
out2 = out2 + "\n</tr>";
}
}
line = "";
count++;
}
}
}
out = '<table cellpadding="0" cellspacing="1" border="1" align="center">' + out + out2 + "</table>";
return out;
}
function getTableDialogAsString(){
out = '<html><body><form name="tableDialog">';
out = out + '<table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#BDD7F7"><tr><td>';
out = out + '<table width="100%" cellpadding="2" cellspacing="2" border="0" bgcolor="#FFFFFF">';
out = out + '<tr bgcolor="#eff7ff">';
out = out + '<td colspan=2 align=center><font size=2px>插入表格</font></td>';
out = out + '</tr>';
out = out + '<tr bgcolor="#ffffde">';
out = out + '<td align=center><font size=2px>行数:</font></td><td align=center><font size=2px>列数:</font></td>';
out = out + '</tr>';
out = out + '<tr bgcolor="#ffffde">';
out = out + '<td align=center><input type="text" name="rows" size="7" value="3"/></td>';
out = out + '<td align=center><input type="text" name="cols" size="7" value="3"/></td>';
out = out + '<tr bgcolor="#ffffde">';
out = out + '<td colspan=2 align=center><input type="button" name="button" value="确定" onclick="window.opener.HyperTextArea.activeArea.insertTable(this.form.rows.value,this.form.cols.value,2,2,true);self.close()"/> <input type="button" name="cancel" value="取消" onclick="self.close()"/></td>';
out = out + '</tr>';
out = out + '</table>';
out = out + '</td></tr></table>';
out = out + '</form></body></html>';
return out;
}
function enableDesignMode(areaName){
try{
if (document.all) {
frames[areaName].document.designMode = "On";
}else{
contentDocument = document.getElementById(areaName).contentDocument;
contentDocument.designMode = "on";
}
self.status = "";
area.setContent(area.html)
}catch(e){
//attempt to recover from any exceptions
exp = "enableDesignMode('"+areaName+"')";
area = HyperTextArea.getArea(areaName);
area.designModeRetryCount++
self.status = "Error in setting designMode property on attempt number "+ area.designModeRetryCount +". Retrying.";
if(area.designModeRetryCount <= 10){
t = setTimeout(exp,100);
}else{
self.status = areaName + " failed to initialize properly";
throw e;
}
}
}
function onHyperTextAreaLoad(areaName) {
self.status = "attempting to set designMode property";
area = HyperTextArea.getArea(areaName);
area.cpWindow = frames['cp' + areaName].window;
//enables the area to determine what form it belongs to
area.form = document.getElementById("hdn"+areaName).form;
//attaches to the forms submit handler only once
formAlreadyStored = false;
for(i=0;i<HyperTextArea.forms.length;i++){
if(area.form == HyperTextArea.forms[i]){
formAlreadyStored = true;
break;
}
}
if(!formAlreadyStored){
onSubmitFunc = area.form.onsubmit;
area.form.onsubmit = function(){
HyperTextArea.updateAllAreas();
if(onSubmitFunc){
onSubmitFunc();
}
}
HyperTextArea.forms[HyperTextArea.forms.length] = area.form;
}
area.setContent(area.html)
if (document.all) {
cp = frames["cp" + areaName];
cp.document.write(getPaletteAsString());
} else {
cp = document.getElementById("cp"+areaName);
d = cp.contentDocument;
d.open();
d.write(getPaletteAsString());
d.close()
}
enableDesignMode(areaName);
area.setContent(area.html)
}
//-->
</script>
<script>
var details = '';
area = new HyperTextArea("area1", details, 450, 200,"");
</script>
</div>
<textarea style="display:none" name="p_z_Z_Details" cols=50 rows=10></textarea>
<table width="100%" cellPadding="0" cellSpacing="0" border="0">
<tr>
<td class="S"> <font color="#FF0000">您可直接从word、excel中将现成资料拷贝过来,经过优化后可能会与原内容不同。</font>
<br><SPAN class=note>说明尽可能详细,以提高信息的可信度,促使您做成生意;</SPAN></td>
</tr>
</table></td>
</TR>
</TBODY></TABLE>
<TABLE cellSpacing=2 cellPadding=3 width="100%" border=0>
<TBODY>
<tr>
<td valign="top" bgcolor=#FFFCF7 width="20%" class=C><b>产品图片:</b></td>
<td class=lh15 bgcolor=#FFF8EE style="position: relative; clip: rect( )">
<TABLE cellSpacing=5 cellPadding=0 width="100%" border=0>
<TR>
<TD> <div id=showpic style="display:"> 图片1:<br>
<img name=uploaded0 src="../images/detail_no_pic.gif" border=0 width=100 height=100>
</div></td>
<td> 图片2:<br> <img name=uploaded1 src="../images/detail_no_pic.gif" border=0 width=100 height=100>
</td>
<td> 图片3:<br> <img name=uploaded2 src="../images/detail_no_pic.gif" border=0 width=100 height=100>
<br> </td>
</tr>
<tr>
<td> <input type='hidden' name='p_z_Z_Picsample' value="">
<div id=uploadpic style="display:none">
</div>
<input type="button" value="上传" name="uploadPicBtn0" onclick="table_display('table100');">
<input type="button" value="删除" name="delPicBtn0" onclick="delete_picture('0');">
</td>
<td> <input type="hidden" value="0" name="picsample_0">
<input type="button" value="上传" name="uploadPicBtn1" onclick="table_display('table101');">
<input type="button" value="删除" name="delPicBtn1" onclick="delete_picture('1');">
</td>
<td> <input type="hidden" value="0" name="picsample_1">
<input type="button" value="上传" name="uploadPicBtn2" onclick="table_display('table102');">
<input type="button" value="删除" name="delPicBtn2" onclick="delete_picture('2');">
<input type="hidden" value="0" name="picsample_2">
</td>
</tr>
<tr>
<td colspan=3><%if session("flag")<>1 then%><div align="right"><span class="note"><img src="../images/offerfaq2.gif" width="14" height="14" align="absmiddle"> </span><span class="S"><a href="/login/vip.asp" target="_blank">点此申请商务会员服务</a></span></div><%else%><%end if%></td>
</tr>
</table>
<table cellSpacing=0 cellPadding=0 width="100%" height="100%" border=0 id="table100" style=display:"none">
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -