| Line 10... |
Line 10... |
| 10 |
<script type="text/javascript" src="../jquery/jqueryui/ui/jquery.ui.dialog.js"></script>
|
10 |
<script type="text/javascript" src="../jquery/jqueryui/ui/jquery.ui.dialog.js"></script>
|
| 11 |
<script type="text/javascript" src="../js/events.js"></script>
|
11 |
<script type="text/javascript" src="../js/events.js"></script>
|
| 12 |
<script type="text/javascript" src="../js/tinymce/tinymce.min.js"></script>
|
12 |
<script type="text/javascript" src="../js/tinymce/tinymce.min.js"></script>
|
| 13 |
<script type="text/javascript">
|
13 |
<script type="text/javascript">
|
| 14 |
$(document).ready(function(){
|
14 |
$(document).ready(function(){
|
| 15 |
$('div.editable').click(function(e){
|
15 |
$('pre.editable').click(function(e){
|
| 16 |
e.preventDefault();
|
16 |
e.preventDefault();
|
| 17 |
$('<div title="Expert Review"><textarea name="abc" style="height:240px;width:500px"></textarea></div>').find('textarea')
|
17 |
$('<div title="Expert Review"><textarea name="abc" style="height:240px;width:500px"></textarea></div>').find('textarea')
|
| 18 |
.val($(this).html())
|
18 |
.val($(this).html())
|
| 19 |
.end()
|
19 |
.end()
|
| 20 |
.dialog( {
|
20 |
.dialog( {
|
| 21 |
height: 470,
|
21 |
height: 470,
|
| 22 |
width: 700,
|
22 |
width: 700,
|
| 23 |
buttons: {
|
23 |
buttons: {
|
| 24 |
"OK": function() {
|
24 |
"OK": function() {
|
| 25 |
inputContent = tinyMCE.activeEditor.getContent();
|
25 |
inputContent = $(this).find('textarea').val();
|
| 26 |
if (inputContent == "" || inputContent == '<p><span style="cursor:pointer;color:blue">Click here to Edit</span></p>'){
|
26 |
if (inputContent == "" || inputContent == 'Click here to Edit'){
|
| 27 |
inputContent = '<span style="cursor:pointer;color:blue">Click here to Edit</span>';
|
27 |
inputContent = 'Click here to Edit';
|
| 28 |
}
|
28 |
}
|
| 29 |
$('#expertReviewHtml').val(inputContent);
|
29 |
$('#expertReviewHtml').val(inputContent);
|
| 30 |
$('div.editable').html(inputContent);
|
30 |
$('pre.editable').html(inputContent);
|
| 31 |
$(this).dialog("close");
|
31 |
$(this).dialog("close");
|
| 32 |
}
|
32 |
}
|
| 33 |
},
|
33 |
},
|
| 34 |
modal: true});
|
34 |
modal: true});
|
| 35 |
tinymce.init({
|
- |
|
| 36 |
selector: "textarea",
|
- |
|
| 37 |
plugins: [
|
- |
|
| 38 |
"advlist autolink lists link image charmap print preview anchor",
|
- |
|
| 39 |
"searchreplace visualblocks code fullscreen",
|
- |
|
| 40 |
"insertdatetime media table contextmenu paste"
|
- |
|
| 41 |
],
|
- |
|
| 42 |
toolbar: "insertfile undo redo | styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image",
|
- |
|
| 43 |
autosave_ask_before_unload: false
|
- |
|
| 44 |
});
|
- |
|
| 45 |
});
|
35 |
});
|
| 46 |
});
|
36 |
});
|
| 47 |
</script>
|
37 |
</script>
|
| 48 |
<link type="text/css" href="../jquery/jqueryui/themes/ui-lightness/jquery.ui.all.css" rel="stylesheet" />
|
38 |
<link type="text/css" href="../jquery/jqueryui/themes/ui-lightness/jquery.ui.all.css" rel="stylesheet" />
|
| 49 |
<style type="text/css">
|
39 |
<style type="text/css">
|
| Line 103... |
Line 93... |
| 103 |
<option title="$source.getSourceUrl()" value="$source.getSource()">$source.getSource()</option>
|
93 |
<option title="$source.getSourceUrl()" value="$source.getSource()">$source.getSource()</option>
|
| 104 |
#end
|
94 |
#end
|
| 105 |
</select>
|
95 |
</select>
|
| 106 |
<br><br>
|
96 |
<br><br>
|
| 107 |
<label for="password">Expert Review</label>
|
97 |
<label for="password">Expert Review</label>
|
| 108 |
<div class="editable" style="border:1px solid red;padding:2px"><span style="cursor:pointer;color:blue">Click here to Edit</span></div><br>
|
98 |
<pre class="editable" style="border:1px solid red;padding:2px">Click here to Edit</pre><br>
|
| 109 |
<label for="sourceUrl">Source Url</label><br>
|
99 |
<label for="sourceUrl">Source Url</label><br>
|
| 110 |
<input type="textbox" name="sourceUrl" id="sourceUrl" style="width:250px"/><br><br>
|
100 |
<input type="textbox" name="sourceUrl" id="sourceUrl" style="width:250px"/><br><br>
|
| 111 |
<input type="hidden" name="expertReviewHtml" id="expertReviewHtml"/>
|
101 |
<input type="hidden" name="expertReviewHtml" id="expertReviewHtml"/>
|
| 112 |
<input type="submit" value="Create" name="submit"></input>
|
102 |
<input type="submit" value="Create" name="submit"></input>
|
| 113 |
</fieldset>
|
103 |
</fieldset>
|