Hello mate,
i was adjusting the Tutorial Module a bit fixing some bug, i noticed in the file:
how to switch text input area to ckeditor same as:
../admin.php?op=addtutorial
in the user submissions this is the link:
../modules.php?name=Tutorials&file=submit
cheers.
i was adjusting the Tutorial Module a bit fixing some bug, i noticed in the file:
how to switch text input area to ckeditor same as:
../admin.php?op=addtutorial
in the user submissions this is the link:
../modules.php?name=Tutorials&file=submit
cheers.
Try this
Open: public_html/modules/Tutorials/submit.php
Find:
Replace With:
Save & Close
As you can see, I did not remove the old code, I just canceled it out with a // and built in a new section. I did a quick test on my site and seemed to post okay, but I did not go crazy on the testing, barely at all. but I believe it should work.
Open: public_html/modules/Tutorials/submit.php
Find:
PHP: [ Select all ]
echo "</select><br \/><br \/>"
.""._TUTADMINDESCRIPTION255."<br \/><textarea name=\"description\" cols=\"60\" rows=\"5\"></textarea><br \/><br \/>";
tutorial_form();
echo " <td colspan=\"9\"><span class=\"gen\">
<textarea name=\"message\" rows=\"40\" cols=\"100%\" wrap=\"virtual\" class=\"post\" onselect=\"storeCaret(this);\" onclick=\"storeCaret(this);\" onkeyup=\"storeCaret(this);\"></textarea>
</span></td>
</tr>
</table>
</span></td>
</tr>
</table>";
Replace With:
PHP: [ Select all ]
echo "</select><br \/><br \/>";
echo _TUTADMINDESCRIPTION255."<br \/><textarea name=\"description\" cols=\"60\" rows=\"5\"></textarea><br \/><br \/>";
echo _TUTADMINTUTORIALTEXT.":<br \/>
<font class=\"tiny\">"._TUTADMINPAGEBREAK."</font><br \/>";
echo "<span class=\"gen\">";
echo Make_TextArea('message', '', 'message', '80%', '230px', false);
echo "</span><br/>";
// echo "</select><br \/><br \/>"
// .""._TUTADMINDESCRIPTION255."<br \/><textarea name=\"description\" cols=\"60\" rows=\"5\"></textarea><br \/><br \/>";
// tutorial_form();
// echo " <td colspan=\"9\"><span class=\"gen\">
// <textarea name=\"message\" rows=\"40\" cols=\"100%\" wrap=\"virtual\" class=\"post\" onselect=\"storeCaret(this);\" onclick=\"storeCaret(this);\" onkeyup=\"storeCaret(this);\"></textarea>
// </span></td>
// </tr>
// </table>
// </span></td>
// </tr>
// </table>";
Save & Close
As you can see, I did not remove the old code, I just canceled it out with a // and built in a new section. I did a quick test on my site and seemed to post okay, but I did not go crazy on the testing, barely at all. but I believe it should work.
Last edited by coRpSE on Tue May 26, 2015 6:55 pm; edited 5 times in total
oh gr8! thank no problem i will test it and i will be back here. :)
PS/ i noticed another stuff need to be fixed, i can post here or i have to open another topic?
PS/ i noticed another stuff need to be fixed, i can post here or i have to open another topic?
nope it's not correct, something wrong with table, i'm trying to fix it.
Try it now. I just tried it on mine and I found there was an error. I just updated the code in the first post I did.
Hello mate, nope white page now.
found out is missing a: ;
here:
echo "</span><br>"
should be:
echo "</span><br>";
--edited--
it should be added also at Waiting Submissions area when you have to approve or deny it.
admin.php?op=subedit&subid=X
found out is missing a: ;
here:
echo "</span><br>"
should be:
echo "</span><br>";
--edited--
it should be added also at Waiting Submissions area when you have to approve or deny it.
admin.php?op=subedit&subid=X
Yeah, on my version, I did not need the ; at the end. Might of been something I re-coded in the past. I fixed my previous post so if others do this, it will not affect them.
ok good mate! and what about the subadd operation?
I will take a look at it later. The technique will be the same as I did before more and likely.
Okay, this one is easier.
Open: public_html/modules/Tutorials/admin/index.php
Find:
Should be on line 1492 and 1493.
Replace with:
Again, as you can see, I didn't remove the old code, I just canceled it out using a // infront of it. That should be it.
Open: public_html/modules/Tutorials/admin/index.php
Find:
PHP: [ Select all ]
tutorial_form();
echo "<td colspan=\"9\"><span class=\"gen\"><textarea name=\"message\" rows=\"40\" cols=\"100%\" wrap=\"virtual\" class=\"post\" onselect=\"storeCaret(this);\" onclick=\"storeCaret(this);\" onkeyup=\"storeCaret(this);\">$t_text</textarea></span></td></tr></table></span></td></tr></table>";
Should be on line 1492 and 1493.
Replace with:
PHP: [ Select all ]
echo Make_TextArea('message', $t_text, 'post', '100%', '300px', true);
echo "<br \/>";
// tutorial_form();
// echo "<td colspan=\"9\"><span class=\"gen\"><textarea name=\"message\" rows=\"40\" cols=\"100%\" wrap=\"virtual\" class=\"post\" onselect=\"storeCaret(this);\" onclick=\"storeCaret(this);\" onkeyup=\"storeCaret(this);\">$t_text</textarea></span></td></tr></table></span></td></tr></table>";
Again, as you can see, I didn't remove the old code, I just canceled it out using a // infront of it. That should be it.