Page 1 of 1

HESK Text Wrap Issue

Posted: Thu Apr 19, 2012 8:55 pm
by tpatterson88
We are using HESK for our knowledgebase. We added $txt=nl2br($txt); to line 589 of the knowledgebase.php page. We did this because text was wrapping when we wrote step-by-step instructions. It fixed the wrapping where the list of KB articles are on the search page, but the text is still wrapped on other pages. Anyone know how to fix this wrapping?

Re: HESK Text Wrap Issue

Posted: Fri Apr 20, 2012 2:13 pm
by Klemen
Not exactly sure what you mean, could you create a screenshot of your wrapping problem?

Re: HESK Text Wrap Issue

Posted: Fri Apr 20, 2012 4:11 pm
by tpatterson88
http://photobucket.com/aztpatterson has three screenshots. One of them is the correct version.

Re: HESK Text Wrap Issue

Posted: Fri Apr 20, 2012 8:12 pm
by Klemen
If your lines are not wrapping not even in the article itself (image 3/3), then the article is not written correctly.

Could you let me know what version of HESK you are using?

If version 2.3 - did you write the article in WYSIWYG editor? Or did you write it as HTML code or as plain text?

Re: HESK Text Wrap Issue

Posted: Fri Apr 20, 2012 9:26 pm
by tpatterson88
We are using HESK version 2.3.


In the helpdesk portion of HESK, it's a "what you see what you get" when submitting information. In the knowledgebase, this isn't the case. We are using the manage_knowledgebase.php?a=add_article&catid=1 link to add the data, but when we type it in with multiple lines, the text is wrapping to one line.

Re: HESK Text Wrap Issue

Posted: Fri Apr 20, 2012 10:31 pm
by tpatterson88
Also, the WYSIWYG Editor setting is enabled. Since we made the mod to line 589 of the knowledgebase page it seems to me that the issue is somehow related to the code that is displaying the data, not the code that is allowing the input of data.

Re: HESK Text Wrap Issue

Posted: Sat Apr 21, 2012 9:18 am
by Klemen
The problem is your article isn't being saved to the database correctly - if it looks fine in the WYSIWYG editor when you write it but not in the knowledgebase, this means that newlines probably aren't being change into <br /> when saved.

This is not the expected behavior and shouldn't happen - it also doesn't in my tests. I'm not sure why it does on your server though.

1. Have you been modifying the manage_knowledgebase.php file? Could you try uploading the original one?

2. What browser and operating system are you using?

3. What server software and PHP version are you using?

4. Let me know if you could you give me access to your help desk to run some tests.

Re: HESK Text Wrap Issue

Posted: Sat Apr 21, 2012 5:02 pm
by tpatterson88
Question #2 in your response helped me find some more info. IE8 is my browser. Most of our department uses IE8. I tested with Chrome and the WYSIWYG does actually work. It appears that the issue is browser-related.

Any idea what settings should be configured for IE8 to work properly with the page?

http://s1166.photobucket.com/albums/q60 ... chrome.jpg shows the difference between Chrome and IE8.

http://s1166.photobucket.com/albums/q60 ... string.jpg shows the error message that comes up in IE8. IE says the page is done loading but with errors.

Re: HESK Text Wrap Issue

Posted: Sun Apr 22, 2012 11:35 am
by Klemen
I don't have IE8 by hand to test right now, but could you try this:

1. open "manage_knowledgebase.php" in Notepad
2. twice in the file replace this code

Code: Select all

true,
with

Code: Select all

true
3. save changes, upload and test.

Did that help?

Re: HESK Text Wrap Issue

Posted: Sun Apr 22, 2012 4:23 pm
by Klemen
OK, I was able to test using IE8 and found out this:

1. the problem occurs if you turn "Compatibility mode" ON, but disappears if you turn Compatibility mode OFF.

2. if you make the change mentioned in my previous post it should work fine with Compatibility mode ON

Re: HESK Text Wrap Issue

Posted: Mon Apr 23, 2012 12:27 pm
by tpatterson88
I replaced both instances of "true," and replaced with "true". We are in business! Thanks