Commit 95dc5843 authored by Carsten  Rose's avatar Carsten Rose
Browse files

Feature #5321 / Plain Link - render mode- only url - implemented

parent 5f49d250
......@@ -240,10 +240,12 @@ class Link {
/*
* mode:
* 0: no output
* 1: text
* 2: url
* 1: <span title='...'>text</span> (no href)
* 2: <span title='...'>url</span> (no href)
* 3: <a href=url>url</a>
* 4: <a href=url>Text</a>
* 5: text
* 6: url
*
* r=render mode, u=url, t:text and/or image.
*
......@@ -280,6 +282,16 @@ class Link {
$this->renderControl[5][1][0] = 0;
$this->renderControl[5][1][1] = 0;
$this->renderControl[6][0][0] = 0;
$this->renderControl[6][0][1] = 5;
$this->renderControl[6][1][0] = 0;
$this->renderControl[6][1][1] = 5;
$this->renderControl[6][0][0] = 0;
$this->renderControl[6][0][1] = 0;
$this->renderControl[6][1][0] = 6;
$this->renderControl[6][1][1] = 6;
}
/**
......@@ -335,8 +347,9 @@ class Link {
$link = '';
// 0-4 URL, plain email
// 0-6 URL, plain email
// 10-14 encrypted email
// 20-24 delete / ajax
switch ($mode) {
// 0: No Output
case '0':
......@@ -394,6 +407,23 @@ class Link {
$link = "<a href=\"javascript: void(0);\" onClick=\"var del = new FR.Delete({recordId:'',sip:'',forward:'" .
$vars[NAME_PAGE] . "'});\" " . $vars[NAME_LINK_CLASS] . ">" . $vars[NAME_TEXT] . "</a>";
break;
// 5: plain text, no <span> around
case '5':
$link = $vars[FINAL_CONTENT];
break;
case '15':
case '25':
throw new UserReportException ("Mode not implemented. internal render mode=$mode", ERROR_UNKNOWN_MODE);
// 5: plain text, no <span> around
case '6':
$link = $vars[FINAL_HREF];
break;
case '16':
case '26':
throw new UserReportException ("Mode not implemented. internal render mode=$mode", ERROR_UNKNOWN_MODE);
}
return $link;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment