Joomla adds an empty space in some components - joomla

I have a problem I've noticed a while ago with a site I'm building.
I've been working with Joomla for a while now and I have never encountered such a problem.
On some components, like featured content, search, hwdvideoshare and some more, quotation marks seem to be added at the very top of the main content area. This causes an extra empty space that pushes the content down.
It's not really acceptable since I am designing a layout that has to be very precise.
Hopefully you guys can help me, I have tried everything.

Open the "index.php" file in the template with notepad++. Then from encoding choose "Convert to UTF8 without BOM", save and reload.

The issue was UTF8 with BOM.
However, it wasn't on the template file.
I started looking for what's in common in all the sites that added the empty space.
It was pagination. Converted the pagination file to UTF8 without BOM and works flawlessly now.

Related

odd issue with funny characters in Joomla/ Jomsocial

I hope someone can help me with this issue.
For a few months (since last August) there has been an ongoing issue on my site with strange characters appearing all over the place - especially in user generated content.
I have searched and searched for answers but nothing ever seems to work, although the most pressing (in the blog component) has been resolved by setting JCE to validate HTML - which is does fine in the Blogging component (EasyBlog) but doesn't anywhere else (where it is less critical but still an issue).
Here is what I have done so far:
Checked the site from multiple machines, multiple browsers - no difference.
Checked the MySQL database and table collation - which are utf8_general_ci
Added AddDefaultCharset UTF-8 and AddCharset UTF-8 .php to the .htaccess files. I played about with these for ages and these two seemed to be the only combination which didn't crash the site.
Have checked the HTML headers and they definitely have the correct content encoding types (set to UTF-8)
I have tried different WSIWIG editors to no avail. Besides it is often in the code output where the characters appear - typically a A next to a »
I have tried a hack to force the connection script to UTF-8 but this causes the site to crash.
If anyone has any ideas at all as to what I can do still ... I'm all ears (please)
Many thanks in advance
If your server is running PHP 5.4+ I would suggest that you try the following solution described in the JCE forums:
In the Editor Global Configuration, set "Entity Encoding" to "UTF-8"
In the "Custom Configuration Variables" field, add:
keep_nbsp:0
The keep an eye out for the JCE 2.3.2 release which will address this issue.
Things to note:
anywhere the spurious â or  is occurring will have to be edited to remove the characters (once the changes above have been applied to JCE).
the problem is Joomla! 2.5.x's use of get_html_translation_table() which relies on default values and PHP 5.4 changed the default encoding parameter to UTF-8. Previously it defaulted to ISO-8859-1
For the core you could try and modify _decode() in /libraries/joomla/filter/input.php, look for the line (around 644):
$trans_tbl = get_html_translation_table(HTML_ENTITIES);
and change it to:
$trans_tbl = get_html_translation_table(HTML_ENTITIES, ENT_COMPAT, 'ISO-8859-1');

Joomla and JomSocial Error

I'm having problem with a client site. I'm not good with Joomla (we mostly do Wordpress), but one of my long-time clients asked me to move a site from another developer that never finished it, so I obliged. The problem is, everything is working great except for the Community page:
http://gettingripped.com/index.php/community
The only errors I'm finding are with the Facebook integration (which they told me the previous dev never finished/fixed). I'm really confused here...anyone out there have any ideas? It seems instead of showing the proper titles that Com_community_somethingElseHere is replacing everything.
Thank you guys in advance for your help!
Seems something is wrong with the en-GB.com_community.ini file.
Location: gettingripped.com/language/en-GB/en-GB.com_community.ini
I could not find the file in the above location!!!
Put this file in that folder and it will work!!!
If you can't find the file to put in the folder, create your own and place it there.. how? Well, google for this string as it is (including double quotes) "en-GB.com_community.ini" and open the first couple of results.
Then copy paste the displayed file content into your own ini file (name it en-GB.com_community.ini) and place it in your en-GB folder.
Load the page and it will show up as it should!

Chinese characters showing as?

I have an issue of showing Chinese characters, look at these 2 pages.
http://www.wufangsingapore.com/instructor-junbeng.php
http://www.wufangsingapore.com/schedule.php
You will realised that the first link which I linked didn't have any issues with the Chinese characters while my second one is showing as ??? despite the fact that it is showing fine in cPanel. Both pages' charset in the meta tag are set to "charset=utf-8" which is supposed to be right. What could be the issue?
Both of them are just pure html, even though they are in PHP extension, they are not reading from any database.
Thanks!
WHile I didn't figure out what really happened.
This is what i did to make the chinese characters appear.
Open up the file in cPanel's File Manager and copy the whole chunk of PHP/HTML code onto the notepad
Save the notepad file as the file name again schedule.php
Reupload via Windows Explorer FTP.

My website is entirely blank, tips to diagnose?

I have an ecommerce site built on OpenCart (1.5.0 i believe), which after inserting tracking code from Alexa.com and a block of code for redirecting to another site went entirely blank. Initially it worked, so I felt it was safe to save over my backups. But after refreshing the pages it was blank, and the 'view source' option in all my browsers (firefox, chrome, safari) revealed that there was no code reaching them. I then began to follow a series of debugging steps:
As my text editor was still open I undid all changes and reuploaded with no changes
I scanned the documents to be sure there were no issues in the text, with no discoveries
I ran it through W3C validation, with 2 warnings which are 1- no character encoding and 2- unable to determine parse mode.
contacted host for a server side restore though their earliest backup was a day after the problem began (it took 3 days of arguing to get them to initiate a restore)
In regards to these validation warnings, I am not sure what encoding should be used for OpenCart, ASCII or UTF-8 (which the validator resorted to) or what, in addition I am not sure if the template used with OpenCart would conflict with it if I were to declare encoding. In addition, I find it hard to believe that such a widely distributed product would have something this simple causing such a huge mistake because then all users would have this issue.
In regards to parse mode, the index page does declare parse mode (in the included header file).
In addition to all this, the validator is also claiming that it is not receiving code at all, which disables any chance of determining problems through that route.
The header and footer were both edited for these additions but are relatively long to include in this. The code used to edit were, for alexa <!-- tracking code here --> inserted into the head section of the header file, and the code for the footer was:
<span style="display:inline-block;width:160px;height:30px;text-align:center;border:#000 1px dotted;font-family:Arial,Helvetica,sans-serif;font-size:11px;background-color:#FFFFFF;"><strong style="display:block;padding:0px;margin:0px;">Reputation Management</strong>Submit Express</span>
If anymore code is needed to help then please let me know, I am not looking for someone to fix my problem but to give me relevant tips to help figure it out myself or if they do provide a fix to educate me as how they managed it so I may be able to use the same debugging method. Thanks!
EDIT: The issue, as discovered thanks to Jay, is "PHP Notice: Undefined index: HTTP_HOST in **/public_html/graphic-shack.com/index.php on line 40" and a google search has not revealed any effective results. This, to my untrained mind is jibberish, clarification would be greatly appreciated as line 40 is in fact a blank line, where as the text around it I can not post for some reason but will be viewable at http://graphic-shack.com/example.html
Open Cart uses UTF-8 throughout, so its definitely best to use that which your theme should set for the browser in the
The first thing I would ask is have you got error reporting set up (NOT OPEN CARTS ONE) that logs php errors?
If not, then you need to do something like
php_flag log_errors on
php_value error_log /path/to/custom/error.log
in your .htaccess file, so that you can log all your php errors to a file. this will need to be somewhere you can get the file, so change the path accordingly so you can view it.
Once you have that, you'll have a good base for working out the problem. I find it hard to believe that opencart has stopped because you added code. The most likely cause is a file missing, blanked or half written accidentally when saving or you've got some extra php code somewhere you shouldn't
== TEST.PHP CONTENT ==
<?php
echo '<pre>' . print_r($_SERVER, true) . '</pre>';
?>

WkHtmlToXSharp not rendering HTML elements as soon as I change the source HTML

I have downloaded WkHtmlToXSharp (which uses WkHtmlToPdf under the hood) and opened the solution.
When I run the test given with the project - CanConvertFromFile, it gives me a nicely formatted PDF output.
But as soon as I delete even a blank space from the source HTML file ( WkHtmlToXSharp.Tests\Resources\page.xhtml) it renders only text with no HTML structure in place i.e. all text on the page is rendered as a single line.
I am finding the same problem with my dev project using WkHtmlToXSharp.
I suspect this is due to change of character encoding of the source file. Do you know what the character encoding should be? Is this an issue with WkHtmlToPdf as well?
Note: Sorry for the slightly misleading tag (WkHtmlToPdf), the site did not allow me to create tag WkHtmlToXSharp.
Many Thanks!
wkhtmltopdf assumes UTF8 as default, but there's a property (WebSettings.DefaultEncoding) which can be used to override the encoding expected.
However, your problem looks more like you are re-using a disposed instance or something similar. May you describe a bit deeper your use case.. is it an ASP.NET application? a console project? are you running under visual studio's dev web server?
I believe the cause of this is in the issue tracker on Pablo's repo. Issue #7: Only works first time
datimson commented 25 days ago
Also, for the sake of helping anyone else who might have this problem, when debugging with WkHtmlToXSharp in ASP.NET you need to stop the ASP Development server before restarting or rebuilding the application - this is what was causing my text only PDF outputs.

Resources