deleting all themes and replacing with a new one

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
14 anni tempo fa
i am building a store around a new theme and i've altered several of the store files, including Productsingrid.ascx (so that items appear in three colums instead of two) - it works well in my new theme but of course selecting any of the existing themes throws the design completely SO ..

i have deleted all the other themes so that they are not selectable, but when i open the store, i get the error
 Theme 'darkOrange' cannot be found in the application or global theme directories. 
even after i had changed the web.config file to my new theme name.

i've changed every instance of the term 'darkOrange' in the project to my new theme name

the changes were to these files:
  NopCommerceStore.csproj       (60 instances)
  web.config                               (1 instance)
  install scripts (dont think these were relevant) (2 instances)

i still get the error.

I notice in the file '  NopCommerceStore.csproj '
that there is also reference to certain images in the 'install' theme (probably not relevant to me anymore)
and there is also many references to images and some .css files in the 'nopClassic' theme (which, as i stated, i have deleted)


Will these referenced files throw an error / not render properly when they are called?

Out of curiosity, is there a particular reason that parts of the 'nopClassic' theme is referenced?

Does anyone know if there is a better way of achieving the result i am looking for without changing all the files?
14 anni tempo fa
hi,

all you will need todo,

Create a new folder in App_Themes for your new theme.

Copy all files from existing theme folder to the new folder and edit, add, etc.

Then delete exting theme folders or move out the app_themes folder to another location so you have a back up.

Now all you need to do is select your new theme within store admin > configuration.

mike..
14 anni tempo fa
thats pretty much whatt i did but the server threw up an error telling me that darkOrange theme could not be found

so i figured it had to be removed from all the places it had been referenced in code

      NopCommerceStore.csproj       (60 instances)
      web.config                               (1 instance)
      install scripts (dont think these were relevant) (2 instances)
14 anni tempo fa
Open web.config file and replace "darkOrange" (<pages theme="DarkOrange">) with your theme name
14 anni tempo fa
it all seems so simple now - yes, i see it should be as simple as changing the web.config file but i was getting the error
 Theme 'darkOrange' cannot be found in the application or global theme directories. 
even after i had changed the web.config file to my new theme name and deleted all the other themes.

the problem was coming from the database:

Table   =     Nop_Setting

setting id          name                                               value                                             description
169                  Display.PublicStoreTheme                  darkOrange                                 The public store theme


I had been viewing the store in the darkOrange theme when i closed the browser down

Then i deleted all the theme folders that i didn't want (including the darkOrange theme)

But, the application was still looking for that theme because the database value was still set to it when it restarted. My solution was just to change the value to my new theme name - if only i could spend less time making problems for myself :)

the lesson: if you are deleting themes, make sure that the last theme you view the store in is not one you are going to delete !!!
_
14 anni tempo fa
Pardon me if i am wrong,

Other than admin no one has the option to change the theme i suppose.

And you donot have to delete those theme files. All you have to do is just copy and past one of the theme files to your new theme folder. Edit the new theme according to your needs. Set this theme in the Configuration settings of the Admin pages.

Finally change the theme name in the webconfig file as well.

<pages theme="YourNewTheme"> (but this is not necessary if you had set in configuratin settings.

still you have problem, start from beginning
14 anni tempo fa
happily i solved my problem last night!!

i am building the shop for someone other than me - so they would have access to this - this is why i wanted them deleted

as i explained, the problem i was having was specific -  because i had deleted the last theme i had been viewing so there was reference in it in the database and the application was looking for it when it restarted
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.