test
Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • cgc0202 Friend
    #140528

    Hello,

    Significance. Professional papers make sure that the text that appears with each article in the front page is set of complete sentences — not truncated as is usually the case in a Joomla-Joomlart page — unless you count the characters manually.

    What is needed is a dynamic character counter that provides a running total as you type. I have seen variations of this feature used in professional sites (not Joomla).

    For example in Twitter the window does not allow you to exceed 140 characters, if I am not mistaken. But this is crude or rather tedious because you only know that you exceed the max, when you click submit. Then, you keep on editing until you get just the correct total number of characters.

    What would be useful would be an extension — a plugin perhaps, that is linked with the article edit menu — that will give you a running total of the number of characters so far typed. The goal is not to exceed the maximum characters allowed in the features article of the JA News FrontPage or the JA News.

    Cornelio

    jsliao Friend
    #302289

    a javascript counter might be able to work as long as you know how to mod your forms

    see link for an example of such a javascript
    http://www.reconn.us/character_counter.html

    cgc0202 Friend
    #302298

    <em>@jsliao 125609 wrote:</em><blockquote>a javascript counter might be able to work as long as you know how to mod your forms

    see link for an example of such a javascript
    http://www.reconn.us/character_counter.html</blockquote>

    Thanks jsliao,

    I am afraid I am technically challenged. I can easily mess up a complex php page. Actually, is there way to have it as a separate “page” in the Backend — where it will pop out as a windown, just like the HTML window?

    I could type something and it will count the total number of characters I have typed?

    I usually have two windows anyway, when I look at the Homepage, Section or Category, so I can look at the layout in the FrontEnd while I edit in the BackEnd.

    Update:

    I was testing it and it has a fixed total number of characters. For the purpose of Joomla-Joomlart, where the JA News Frontpage text, other JA News Frontpage “non-feature articles” differ in total number, as well as those of the JA News Section module lead article have different total number of characters, a better one would be where I have a running total of characters

    Significance of the running total characters script

    For example, in the Homepage:

    JA News FrontPage (feature article) => 400 characters
    JA News Frontpage (other articles) => 250 characters
    JA News (lead article) => 120 characters

    I can fix it so that it will be complete statements, sequentially at:

    * 120 characters
    * 250 total characters (including the previous 120 characters)
    * 400 characters (including the previous 250 characters)

    satisfying all the above different potential designation of the same article, as the feature article in the JA News Frontpage is relegated to just another article in the JA News Frontpage or when it becomes a lead article in the JA News.

    As outlined, a script that will be have a running total — shown in a window box (rather than a single line box to allow some sort of layouting will be more versatile than a fixed total number of characters, as shownn in the link.

    The total characters, also complete statement, for the Intro pages of the Sections and Category will be defined by the placement of the “Read more”.

    It is a very tedious process to accomplish the above, but it will create a very elegant and professional looking website.

    Cornelio

    cgc0202 Friend
    #302302

    Hi jsliao,

    I am doing a search from your lead, and I am seeing mostly the same as the link you showed. I have not found one yet similar to what I outlined.

    Alternative: Can I do this using as many clones of the scripts

    First window: 120 characters
    Second window: 130 characters (=> First + Second = 250)
    Third window: 150 characters (=> First + Second + Third = 400)

    etc.

    Rather more cumbersome, but if it works….

    Cornelio

    cgc0202 Friend
    #302303

    Hi jsliao and others,

    Thanks for pointing the key words I need to narrow the search. I found one. It works as I outlined in the original thread when I tried their box..

    Cut & Paste Character count script written by JavaScript Kit
    http://www.javascriptkit.com/script/script2/charcount.shtml

    Need some help:

    I know how to paste the script below into a php page. However, how do I make the file show as a module or something in the backend?

    I wonder if it can be converted into a module zip file and then installed via the Extensions into the Admin page? My old iBook does not create functional zip files. I tried it before, already. 🙁

    Security Issues:
    If I understand correctly, adding an interactive script can be exploited by malicious individuals who might be able to get into the site. I know for example that the simple Shout Box that I use can be accessed, even if I restricted the permissions to “Registered users”.

    How can this security issues be avoided with this feature?

    Cornelio

    Cut & Paste Character count script written by JavaScript Kit
    [PHP]<form method=”POST”>

    <table border=”0″ cellspacing=”0″ cellpadding=”0″>
    <tr>
    <td width=”100%”>
    <textarea rows=”12″ name=”charcount” cols=”60″ wrap=”virtual”></textarea>
    </td>
    </tr>
    <tr>
    <td width=”100%”><div align=”right”><p><input type=”button” value=”Calculate Characters”
    onClick=”countit(this)”> <input type=”text” name=”displaycount” size=”20″></p>
    <div align=”center”><center><p>This free script provided by
    <a href=”http://javascriptkit.com”>JavaScript
    Kit</a></p>
    </center></div></div></td>
    </tr>
    </table>

    </form>

    <script language=”JavaScript”>

    function countit(what){

    //Character count script- by javascriptkit.com
    //Visit JavaScript Kit (http://javascriptkit.com) for script
    //Credit must stay intact for use

    formcontent=what.form.charcount.value
    what.form.displaycount.value=formcontent.length
    }
    </script>[/PHP]

    mj1256 Friend
    #302345

    quick and easy, use word, it has a word and character counter in it, look under menu tools/word count

    then copy and paste in note pad to remove the word coding, and then copy and paste in ot your editor

    I beleive that textpad also has this feature and you do not even have to do the copy and paste intp notepad to remove the word encoding.

    cgc0202 Friend
    #302371

    <em>@mj1256 125682 wrote:</em><blockquote>quick and easy, use word, it has a word and character counter in it, look under menu tools/word count

    then copy and paste in note pad to remove the word coding, and then copy and paste in ot your editor

    I beleive that textpad also has this feature and you do not even have to do the copy and paste intp notepad to remove the word encoding.</blockquote>

    Thanks MJ,

    I am a Mac User. I have the Microsoft Office but I selfom use it anymore, especially the World, for the information you stated — the need for extra copy and paste. I use PageSpinner mostly as my text pad or to perform basic html and other scripting.

    The Javascript I mentioned in my previous post does exactly as I outlined. I even tested it alreay, as shown in the Demo page. I can do the messy editing there then copy directly into my article edit page — no need to open any other application than those I already have opened.

    I have an old iBook G4 (almost 6 years now) but I am waiting for the Snow Leopard to be introduced, and I usually wait for the next generation computer to arrive before I buy any Mac computer — so that means more than likely sometime next year. I hope my iBook will hold long enough before then.

    Convert javascript to working module. What I need most, as I stated above, is a way to convert the script into a functional module. I am not sure if it is just a simple conversion to a zip file. The zip file I create in my old computer does not result into a working file, when unpacked.

    If you or any of the readers know or can help convert the javasscript code I included in the previous post, into a working module zip file, I would appreciate the help.

    Cornelio

    mj1256 Friend
    #302405

    Cornelio, i didn’t mean to come off so flip, one for the links in my sig may be an option for you

    jsliao Friend
    #302585

    if you use firefox, you could give this extension a try
    https://addons.mozilla.org/en-US/firefox/addon/4718

Viewing 9 posts - 1 through 9 (of 9 total)

This topic contains 9 replies, has 3 voices, and was last updated by  jsliao 15 years, 7 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum