Simple Machines Community Forum

SMF Development => Bug Reports => Fixed or Bogus Bugs => Topic started by: adapa on March 26, 2012, 04:06:06 PM

Title: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: adapa on March 26, 2012, 04:06:06 PM
Ok, i'm at my wit's end, i can not upload a theme & my husband it getting tired of making  changes to my site.
specifics;
I'm running 2.0.2,
when i attempt to add a theme i get; "Unable to connect to the server. Please try using this URL ...",

I then DL a theme, zipped to my DT & use the "upload a pkg" & get "Package upload failed due to the following error:"Although the package was downloaded to the server it appears to be empty. Please check the Packages directory, <snip>"

Both of these errors happen on both of my windows 7 machines, but *not* oh my husbands MAC.....<sigh> when he's logged on as me to my forum.

My permissions are all set to writable, I've dumped my temp i-net files etc, tried firefox intead of chrome.

Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 26, 2012, 04:19:33 PM
Theme's aren't packages, Adapa...

Does that give you enough of a clue? ;)

Welcome to the forum, by the way!
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: adapa on March 26, 2012, 04:30:49 PM
I am such a n00b
:-[
thank you for being nice.....
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 26, 2012, 04:33:08 PM
No problem, darlin'! :)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 26, 2012, 04:34:08 PM
Actually it would be good if the one area of admin handled themes as well as mods. We have talked about this, and it is possible, but it hasn't been done due to the amount of recoding that would be required, and the fact that there are higher priorities.
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 26, 2012, 04:45:15 PM
Seems like damned good plan, that!
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 26, 2012, 04:47:42 PM
Y'know what? As an easy interim measure, it would be a rather good plan to have a simple warning in the package manager section: "Please note that themes should be installed via the Manage and Install (http://www.example.com) page."
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 26, 2012, 05:06:13 PM
Quote from: K@ on March 26, 2012, 04:45:15 PM
Seems like damned good plan, that!

Too! :)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 26, 2012, 05:10:31 PM
Maybe we should move this to Bug Reports just to annoy the devs. ;)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 26, 2012, 05:18:08 PM
Quote from: K@ on March 26, 2012, 04:45:15 PM
Seems like damned good plan, that!

(http://www.katzy.dsl.pipex.com/Smileys/giggle.gif)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: adapa on March 26, 2012, 06:18:21 PM
thank you guys for understanding my pain...
8)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 27, 2012, 05:15:21 AM
You could always blame your other-half, for not showing you, properly.

I'm sure that's what mine would do, in the circumstances... ;)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 28, 2012, 03:00:04 AM
Moved to Bug Reports. Not really a bug as such, but we do get this sort of confusion every so often. I'd call it a minor usability issue.

Quote from: Antechinus on March 26, 2012, 04:47:42 PM
Y'know what? As an easy interim measure, it would be a rather good plan to have a simple warning in the package manager section: "Please note that themes should be installed via the Manage and Install (http://www.example.com) page."
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Aleksi "Lex" Kilpinen on March 28, 2012, 03:01:15 AM
Changed status to confirmed :D
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 28, 2012, 03:20:22 AM
Now we just have to wait for someone to try and install a mod via the Themes page. :D
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 28, 2012, 06:05:10 AM
This kinda echoes why I never switched to SMV v2.

To me, the way the admin section is laid out seems totally... dare I say...

(http://www.katzy.dsl.pipex.com/Smileys/illogical.gif)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: emanuele on March 28, 2012, 06:17:27 AM
/me refuses to change the way SMF works. :P
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 28, 2012, 06:37:42 AM
It works?!?!?

(http://www.katzy.dsl.pipex.com/Smileys/giggle.gif)

[/teasing]
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: emanuele on March 28, 2012, 07:14:29 AM
Don't ask me, I just assume it works. :P
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: IchBin™ on March 28, 2012, 01:02:12 PM
Quote from: emanuele on March 28, 2012, 06:17:27 AM
/me refuses to change the way SMF works. :P

OFF WITH HIS HEAD!
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 28, 2012, 04:21:47 PM
Quote from: K@ on March 28, 2012, 06:05:10 AM
This kinda echoes why I never switched to SMV v2.

To me, the way the admin section is laid out seems totally... dare I say...

(http://www.katzy.dsl.pipex.com/Smileys/illogical.gif)

It's actually laid out much the same as 1.1.x. :P
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 28, 2012, 04:51:54 PM
[pantomime mode]

OH NO IT ISN'T!

[/pantomime mode]
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: IchBin™ on March 28, 2012, 05:25:12 PM
What are the differences that you don't like K@?
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 28, 2012, 05:57:47 PM
It's new innit. Damned new-fangled softwarey stuffz. When I were a lad things were different. ;)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 29, 2012, 06:10:55 AM
You were a lad?!?!? ;)

In a word "Everything".

That whole dropdown is just totally weird, to me.

I never, ever go to "Core features" thing and, well, the whole thing seems "Cobbled-together", to me.

Installing Helios made things better, though, coz the admin section's laid-out in the 1.1.16 way, quite a bit.

I thought it was just me being weird. But, I've heard the same thing from many others, too.

But, it's no hassle, coz I don't mind sticking with v1.1.16. It does what we want, so all's good.

For me, personally, I can see advantages in having Admin laid-out in much the same way as the "UserCP" mod laid-out your profile.
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: emanuele on March 29, 2012, 11:42:32 AM
Subs-Packages.php
Code (find) Select
// Nothing?
if (empty($packageInfo))
return 'package_get_error_is_zero';

Code (replace with) Select
// Nothing?
if (empty($packageInfo))
{
// It could be a theme, so better tell him.
$packageInfo = read_tgz_file($boarddir . '/Packages/' . $gzfilename, '*/theme_info.xml', true);
if (!empty($packageInfo))
return 'package_get_error_is_theme';
else
return 'package_get_error_is_zero';
}


PackageGet.php
Code (find) Select

fatal_lang_error('package_upload_error_broken', false, $txt[$context['package']]);

Code (add before) Select

$txt[$context['package']] = str_replace('{MANAGETHEMEURL}', $scripturl . '?action=admin;area=theme;sa=admin;' . $context['session_var'] . '=' . $context['session_id'], $txt[$context['package']]);



Errors.english.php
Code (find) Select

$txt['package_get_error_packageinfo_corrupt'] = 'SMF was unable to find any valid information within the package-info.xml file included within the Package. There may be an error with the modification, or the package may be corrupt.';

Code (add before) Select
$txt['package_get_error_is_theme'] = 'The package you are trying to install is a theme and not a mod, please use the <a href="{MANAGETHEMEURL}">Themes and Layout</a> management page to upload it';
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 29, 2012, 12:06:46 PM
I do love this dev stuff, out in the open.

Just proves that we're trying to give our members what they want.

Good stuff!
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Spuds on March 29, 2012, 01:30:03 PM
Quote from: K@ on March 29, 2012, 06:10:55 AM
In a word "Everything".

That whole dropdown is just totally weird, to me.
Just want to make sure that you realize you can enable the left side menus instead of the dropdowns by clicking the little << icon ... you know the one thats really small and really hard to see or find that has not hover text to tell you what its for ...  kinda obvious really :P
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: emanuele on March 29, 2012, 01:41:18 PM
/me has a very stupid idea:
...why not remove that icon and put a setting in the profile?...
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Aleksi "Lex" Kilpinen on March 29, 2012, 02:00:20 PM
There is a setting in the profile, unless I'm mistaken.
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: emanuele on March 29, 2012, 02:13:35 PM
I don't use the profile page that much... lol
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 29, 2012, 03:41:14 PM
Yeah, I did know that, ta.

It's the top menus that do my head in, amongst other things.

It's really not a problem, though. Everyone at my place is quite happy with what we have. So, no point in even considering upgrading, for us.

Bit like my friend Bill, who died, not long ago. He had Windows 98 on his rig and, as it did exactly what he wanted it to do, he never bothered moving-on, from that.

Boy, did THAT guy know his stuff, too!
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 29, 2012, 04:09:28 PM
Quote from: K@ on March 29, 2012, 06:10:55 AM
You were a lad?!?!? ;)

In a word "Everything".

That whole dropdown is just totally weird, to me.

I have thought about this. Although I find the drops quite easy to work with myself, I do think that for admin they could be improved. IMO it would be better if admin used something more like a megamenu setup, so that admin options were listed visibly on one level of drop menu. This would mean less reliance on human memory to find things.

Example and caveats here: http://www.uie.com/articles/mega_menus/

The caveats should be somewhat less of a problem for SMF admin, if things are done sensibly.

TBH I really think the control pages (admin, profile, etc) need to have their navigation rationalised. The current method of offering two systems is just bonkers, and sidebar menus are problematic when trying to accommodate a range of screen sizes.


QuoteI never, ever go to "Core features" thing and, well, the whole thing seems "Cobbled-together", to me.

The Core Features page is not intended to be used very often. Most people will only use it when they are setting up a new site, but for that purpose it works well as it allows people to select and enable large chunks of forumey stuff that they may or may not want. That's all it's meant for. :)


QuoteFor me, personally, I can see advantages in having Admin laid-out in much the same way as the "UserCP" mod laid-out your profile.

You mean sorta like the Core Features page? :D
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 29, 2012, 04:10:49 PM
Quote from: Spuds on March 29, 2012, 01:30:03 PM
Quote from: K@ on March 29, 2012, 06:10:55 AM
In a word "Everything".

That whole dropdown is just totally weird, to me.
Just want to make sure that you realize you can enable the left side menus instead of the dropdowns by clicking the little << icon ... you know the one thats really small and really hard to see or find that has not hover text to tell you what its for ...  kinda obvious really :P

So I suppose you want me to improve that. :D
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 29, 2012, 04:15:36 PM
That looks damned promising, Ant!

How much of a pain in the Aris would that be to include, out of curiosity?
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 29, 2012, 04:38:54 PM
Very easy, for 2.0. A little bit more tricky to implement for 1.1.x, but not that hard. I actually did rewrite the 1.1.x sidebar menus as a clickable drop at one stage. That's simple to do. Basically you get exactly the same menu, but it can be made to vanish when you want more space. That was an idea for mobile and would not be ideal for desktop, but in general menu revamping isn't that big a deal.

At the moment I'm playing with other aspects of the gui, primarily template markup, but a bit later I'll run through some better menu options and play around with them. :)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 29, 2012, 04:42:03 PM
If you want a kinda beta-tester, with access to a test forum, I'm at your service!
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 29, 2012, 04:45:02 PM
Yup. No worries. :)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 29, 2012, 04:47:04 PM
(http://www.katzy.dsl.pipex.com/Smileys/c014.gif)
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 29, 2012, 05:00:52 PM
Incidentally, there are shots of the tweaked 1.1.x menu here: http://www.simplemachines.org/community/index.php?topic=431813.msg3027051#msg3027051

Not that I would do this for a default desktop theme, but it is easy to change menus.
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: kat on March 29, 2012, 05:04:35 PM
Looks worth working on, mate.

Kudos and all that stuff!
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 29, 2012, 05:13:22 PM
Heyyyyyyyyyyyyyyyyyyyy, I just had an idea. How does this sound just for fun? I make it like those screenshots (content arranged like standard sidebar menu) but fixed in place at the left side of your screen. The height would be set to 100% of your screen height, with scrollable content within the actual menu so the entire menu can be found even on smallish screens. Menu is collapsible of course.

Advantage of this is you get the familiar menu layout, but it is accessible no matter where you are on an admin page, without taking up room all the time. Might be worth messing with just to see how it goes.
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Aleksi "Lex" Kilpinen on March 29, 2012, 11:07:01 PM
What I think would change in the current admin menu, if nothing was moved around and the actual admin side remained the same.

You know, now that you click admin in the forum menu, you get a whole new menu bar under forum's own menu in the admin section, and it is yet further divided in to main sections like Configuration and sub-sections like Features and Options - why are the main sections not already in the forum menu admin dropwdown? If they were, I could get to the right section of the admin panel with one click.
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 30, 2012, 01:04:55 AM
Worth thinking about for sure.
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: Antechinus on March 30, 2012, 02:59:06 AM
Quote from: emanuele on March 29, 2012, 11:42:32 AM
Subs-Packages.php
Code (find) Select
// Nothing?
if (empty($packageInfo))
return 'package_get_error_is_zero';

Code (replace with) Select
// Nothing?
if (empty($packageInfo))
{
// It could be a theme, so better tell him.
$packageInfo = read_tgz_file($boarddir . '/Packages/' . $gzfilename, '*/theme_info.xml', true);
if (!empty($packageInfo))
return 'package_get_error_is_theme';
else
return 'package_get_error_is_zero';
}


PackageGet.php
Code (find) Select

fatal_lang_error('package_upload_error_broken', false, $txt[$context['package']]);

Code (add before) Select

$txt[$context['package']] = str_replace('{MANAGETHEMEURL}', $scripturl . '?action=admin;area=theme;sa=admin;' . $context['session_var'] . '=' . $context['session_id'], $txt[$context['package']]);



Errors.english.php
Code (find) Select

$txt['package_get_error_packageinfo_corrupt'] = 'SMF was unable to find any valid information within the package-info.xml file included within the Package. There may be an error with the modification, or the package may be corrupt.';

Code (add before) Select
$txt['package_get_error_is_theme'] = 'The package you are trying to install is a theme and not a mod, please use the <a href="{MANAGETHEMEURL}">Themes and Layout</a> management page to upload it';


This basically looks great and should be committed, but I'd make a couple of minor changes to the wording of the text strings.

Code (find) Select

$txt['package_get_error_packageinfo_corrupt'] = 'SMF was unable to find any valid information within the package-info.xml file of the package. There may be an error with the modification, or the package may be corrupt.';


Code (add before) Select
$txt['package_get_error_is_theme'] = 'The package you are trying to install is a theme and not a mod. Please use the <a href="{MANAGETHEMEURL}">Themes and Layout</a> management page to upload it';


And one extra idea here: if we add an anchor to the relevant section header, the link could take people straight to the upload section. Something like this:

Themes.template.php:

Find:

// Warn them if theme creation isn't possible!
if (!$context['can_create_new'])
echo '
<div class="errorbox">', $txt['theme_install_writable'], '</div>';

echo '
<form action="', $scripturl, '?action=admin;area=theme;sa=install" method="post" accept-charset="', $context['character_set'], '" enctype="multipart/form-data" onsubmit="return confirm(\'', $txt['theme_install_new_confirm'], '\');">
<div class="cat_bar">
<h3 class="catbg">
<span class="ie6_header floatleft"><a href="', $scripturl, '?action=helpadmin;help=theme_install" onclick="return reqWin(this.href);" class="help"><img src="', $settings['images_url'], '/helptopics.png" class="icon" alt="', $txt['help'], '" /></a> ', $txt['theme_install'], '</span>


Replace:

// Warn them if theme creation isn't possible!
if (!$context['can_create_new'])
echo '
<div class="errorbox">', $txt['theme_install_writable'], '</div>';

echo '
<form action="', $scripturl, '?action=admin;area=theme;sa=install" method="post" accept-charset="', $context['character_set'], '" enctype="multipart/form-data" onsubmit="return confirm(\'', $txt['theme_install_new_confirm'], '\');">
<div class="cat_bar">
<h3 class="catbg">
<a href="', $scripturl, '?action=helpadmin;help=theme_install" onclick="return reqWin(this.href);" class="help" id="hey_use_this_bit"><img src="', $settings['images_url'], '/helptopics.png" class="icon" alt="', $txt['help'], '" /></a> ', $txt['theme_install'], '


Then the text string becomes something like:

Code (add before) Select
$txt['package_get_error_is_theme'] = 'The package you are trying to install is a theme and not a mod. Please use the <a href="http://whatever.com/index.php?action=admin;area=theme;sa=admin;#hey_use_this_bit">Themes and Layout</a> management page to upload it';


Which is dodgey url syntax that I can't be bothered figuring out right now, but I'm sure you get the idea. :)

ETA: Another thought. It may be best to reverse the order of two of the sections on the theme management page. Really, I think what most people will want is the sections that actually manage their forum on top, with the supposedly "Latest and greatest themes" at the bottom.

If the page is laid out like:

Themes and Layout Settings

Install a New Theme

Latest and Greatest Themes

I think that would be more useful. Once someone is already looking at the installation form, then they can scroll down a bit and check out the latest themes if they want to.
 
Title: Re: I can't change my theme on my win7 rigs but my husband can on his MAC...
Post by: emanuele on April 28, 2012, 03:50:38 PM
Applied all the code Ant.

Quote from: Antechinus on March 30, 2012, 02:59:06 AM
ETA: Another thought. It may be best to reverse the order of two of the sections on the theme management page. Really, I think what most people will want is the sections that actually manage their forum on top, with the supposedly "Latest and greatest themes" at the bottom.

If the page is laid out like:

Themes and Layout Settings

Install a New Theme

Latest and Greatest Themes

I think that would be more useful. Once someone is already looking at the installation form, then they can scroll down a bit and check out the latest themes if they want to.
Then let's move this and the latest packages to the end of the main admin area?