Jump to content


Photo

Home Link Downloads ZIP folder

home link zip file problem download

  • Please log in to reply
18 replies to this topic

#1 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 10 November 2017 - 01:06 AM

Hi Guys, I hope all is well and you are having a splendid week.

 

I have a problem with a website I am trouble shooting at the moment.

 

http://www.mala.co.uk/#

 

When you click the 'HOME' it downloads a folder with the PHP & HTML files.

 

Can you help me stop it doing this?

 

Kind Regards



#2 TimW

TimW

    Advanced Member

  • Members
  • PipPipPip
  • 270 posts
  • Gender:Male
  • Location:West Country
  • Experience:Intermediate
  • Area of Expertise:Nothing

Posted 10 November 2017 - 10:53 AM

Er, the 'HOME' link points to a folder called MALA and not to the homepage.

You are welcome

TW



#3 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 14 November 2017 - 10:59 AM

Hi Tim, many thanks for you help it is much appreciated. I am unsure why all of a sudden the HOME link is now pointing to the MALA folder instead of the index page. The contents of the folder are the same as what is included in the main folder (header.php, footer.php, gruntfile.js, index.html & menu_helper.php). Is there a reason why this is happening and pointing to this folder?

 

I have to reconstruct the website that I have downloaded from FTP and make some changes to it and then re-upload. When I open the index page in Dreamweaver it looks nothing like what is presented to you in a web browser.

 

The previous designer has used a splash screen that then takes you to the main site screen and a special menu that appears when you hover over it. Also he has used a special typeface that is remotely linked to the website (MUSEO Sans).

 

Any advice to get the website in order on my machine to make the HOME page link back to the home page and not a folder would be MASSIVELY appreciated.

 

Kind Regards,

Gavin



#4 fisicx

fisicx

    Web Guru

  • Privileged
  • PipPipPipPipPip
  • 1,572 posts
  • Gender:Male
  • Location:Aldershot
  • Experience:Intermediate
  • Area of Expertise:Designer/Coder

Posted 14 November 2017 - 11:15 AM

When I open the index page in Dreamweaver it looks nothing like what is presented to you in a web browser.

 

There is no reason why it should. Dreamweaver will only process the files it's able to. This won't include PHP and JS is unlikely to work.



#5 Jack

Jack

    NaN

  • Moderators
  • PipPipPipPipPip
  • 3,205 posts
  • Gender:Male
  • Location:Jersey Channel Islands
  • Experience:Advanced
  • Area of Expertise:Web Designer

Posted 14 November 2017 - 11:58 AM

Does your home folder have an index.php or index.html file? It's possible your server is doing this because there's no default file it can find. It's still really unusual though, forcing a folder to download is something you tend to code intentionally.



#6 fisicx

fisicx

    Web Guru

  • Privileged
  • PipPipPipPipPip
  • 1,572 posts
  • Gender:Male
  • Location:Aldershot
  • Experience:Intermediate
  • Area of Expertise:Designer/Coder

Posted 14 November 2017 - 02:16 PM

The home link is to a folder called /mala. That why it's not working.



#7 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 14 November 2017 - 05:56 PM

Hi Web Guru & Nan. I hope all is well and you are having a splendid week. Many thanks for your time answering my question.

 

"There is no reason why it should. Dreamweaver will only process the files it's able to. This won't include PHP and JS is unlikely to work."

What I need to do is make some changes to the website that as the previous designer has disappeared. I have been given the FTP details and downloaded a program named 'Mountain Duck' to get access to the files. I have some basic web design skills and have always used Adobe Dreamweaver or Muse to create websites. What I thought I could do is download the files via FTP and then open them in Dreamweaver and link certain parts and make the changes in that particular program. I assumed that the previous designer would have used the same program to create the pages. When I open index.html it shows the basics of the page but then I am a little bit lost on how to get all of the different parts linked up. The previous designer has used some techniques that are new to me (splash screen & menu) that I am assuming is js.

 

"Does your home folder have an index.php or index.html file? It's possible your server is doing this because there's no default file it can find. It's still really unusual though, forcing a folder to download is something you tend to code intentionally."

I have downloaded all of the folder content to my machine and there is a  index.html file within that folder. The only part that would not download properly is a folder named 'logs' that would not download properly. I was unsure how else to make the changes other than download the web files to my local machine, make the changes, and then re-upload via FTP. It certainly is strange as the company who own the website said this only started happening recently and it had been working fine for a while.

 

Any advice is massively appreciated.

Kind Regards



#8 fisicx

fisicx

    Web Guru

  • Privileged
  • PipPipPipPipPip
  • 1,572 posts
  • Gender:Male
  • Location:Aldershot
  • Experience:Intermediate
  • Area of Expertise:Designer/Coder

Posted 14 November 2017 - 06:54 PM

The site is a mix of HTML, CSS, JS and PHP

 

Dreamweaver won't ever work the way you want it to. If you want to make the changes you need to edit the code. You won't be able to use WYSIWYG editor.

 

The logs file you can ignore you don't need it.



#9 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 14 November 2017 - 07:08 PM

Good evening,

 

Ah yes OK. I was hoping to make any changes and then test the site before it goes live to avoid any more problems and it getting worse. I am more used to working in a program like Dreamweaver to see what is happening.

 

I am a little unsure what file to edit to make the Home link point to the Home page rather than the MALA folder download.

 

Which program would you recommend to edit the code and which file do I edit with it being the menu at the top?

 

I have a feeling that it is linking to the folder so not to play the splash screen every time you go back to the HOME page? Is this correct?

 

Kind Regards


Edited by Gee_suss, 14 November 2017 - 07:49 PM.


#10 fisicx

fisicx

    Web Guru

  • Privileged
  • PipPipPipPipPip
  • 1,572 posts
  • Gender:Male
  • Location:Aldershot
  • Experience:Intermediate
  • Area of Expertise:Designer/Coder

Posted 14 November 2017 - 07:50 PM

I suspect it's in header.php.

 

Look for the home link and delete the /mala and it should work again

 

Dreamweaver will do the job - you just need to switch to code view.



#11 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 14 November 2017 - 08:09 PM

Hello,

 

I hope you do not mind but I have attached the header.php as I am not able to see the link for the HOME page.

 

Do you think that the MALA folder is there so that when you are browsing the website and you need to go back to the Home page it does not play the splash screen?

 

So I would edit the file in Dreamweaver and then replace the existing file on the server using FTP?

 

Kind Regards

Attached Files



#12 fisicx

fisicx

    Web Guru

  • Privileged
  • PipPipPipPipPip
  • 1,572 posts
  • Gender:Male
  • Location:Aldershot
  • Experience:Intermediate
  • Area of Expertise:Designer/Coder

Posted 14 November 2017 - 08:17 PM

Change line 54 to:

 

<li class="<?php echo $home; ?> show-for-medium-up"><a href="/">Home</a></li>


Edited by fisicx, 14 November 2017 - 08:18 PM.


#13 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 14 November 2017 - 08:26 PM

Hi fisicx,

 

Many thanks for looking at the header file, it is much appreciated!

 

Just to make 100% sure as I am ultra scared about editing a file on the live website. Will the website still open up with the splash screen but when you click the Home page link within the website it will not play the splash screen again?

 

UPDATE: I have just made the change to the header.php and it does indeed play the splash page every time you go to the Home page. Is there a way so that it plays the splash page once and once only and when you navigate to the Home page within the site it does not play it again?

 

Kind Regards


Edited by Gee_suss, 14 November 2017 - 08:39 PM.


#14 fisicx

fisicx

    Web Guru

  • Privileged
  • PipPipPipPipPip
  • 1,572 posts
  • Gender:Male
  • Location:Aldershot
  • Experience:Intermediate
  • Area of Expertise:Designer/Coder

Posted 14 November 2017 - 08:43 PM

Probably.

 

I'd need all the site files. Can you zip them up and post here.

 

Why do they even want a splash page? It's a pointless barrier to the website.



#15 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 14 November 2017 - 08:50 PM

Hi fisicx,

 

No worries, please find attached. These are the files I have downloaded and not emended the header.php file as I did that live via FTP.

 

I know! I totally agree. But they were very insistent on that splash screen but I will definitely try and advise them not to have it as it only serves to make people wait more time to enter the site!

 

Many thanks once again!

 

Kind Regards,

Attached Files



#16 fisicx

fisicx

    Web Guru

  • Privileged
  • PipPipPipPipPip
  • 1,572 posts
  • Gender:Male
  • Location:Aldershot
  • Experience:Intermediate
  • Area of Expertise:Designer/Coder

Posted 16 November 2017 - 07:33 AM

I've looked at the files and it's not a simple fix. Get rid of the splash page and it becomes a simple fix.

 

If you want me to do the work then I need to charge.

 

As an aside, there are loads of issues with the site apart from the splash page.



#17 Jack

Jack

    NaN

  • Moderators
  • PipPipPipPipPip
  • 3,205 posts
  • Gender:Male
  • Location:Jersey Channel Islands
  • Experience:Advanced
  • Area of Expertise:Web Designer

Posted 16 November 2017 - 09:51 AM

Can't you just change

<li class="<?php echo $home; ?> show-for-medium-up"><a href="/MALA">Home</a></li>

to just a forward slash and remove the /MALA part? That's why the link is going to that directory.



#18 Gee_suss

Gee_suss

    Forum Newcomer

  • Members
  • Pip
  • 8 posts

Posted 16 November 2017 - 12:21 PM

Hi Guys, many thanks for your time to look at my problem.

 

fisicx: I totally agree the splash page serves no purpose and is only making this particular problem worse. Many thanks for taking time to look at the files and I really appreciate it. Hypothetically how would one get rid of the splash page and have the website just go straight to the Home page?

 

Jack: You are totally right and I have done exactly what fisicx and you have suggested so the problem of the folder downloading has now stopped. The new problem is when you first navigate to the website the splash page activates and then takes you to the website. When you are within the website and navigate to the different pages when you go back to the home page the splash page plays when you go back to the Home page. What I would like is that after the first time you see that splash page you do not see it again when navigating within the site. I totally agree with fisicx above saying that the splash page is not needed and only serves to delay accessing the website. I hope that makes sense :)

 

What I have seen is that perhaps a cookie could be used to see if that person has been to the website before. If they are a first time visitor the splash page plays. If they are a returning visitor the cookie identifies this and the splash page does not play.

 

Kind Regards


Edited by Gee_suss, 16 November 2017 - 01:22 PM.


#19 Jack

Jack

    NaN

  • Moderators
  • PipPipPipPipPip
  • 3,205 posts
  • Gender:Male
  • Location:Jersey Channel Islands
  • Experience:Advanced
  • Area of Expertise:Web Designer

Posted 16 November 2017 - 01:15 PM

What I have seen is that perhaps a cookie could be used to see if that person has been to the website before. If they are a first time visitor the splash page plays. If they are a returning visitor the cookie identifies this and the splash page does not play.


Cookies should achieve what you want, here's one way to implement it.

Change index.html to index.php

The top of the file should be changed to include this:

<?php
  include('header.php');

  // sets a cookie for the splash page visibility for 10 years
  if( count($_COOKIE) > 0 && !isset($_COOKIE['displaySplash'] ) ){
    setcookie(
      'displaySplash',
      '',
      time() + (10 * 365 * 24 * 60 * 60) 
    );
  };
?>

I'm not actually sure how you would do a never expire cookie in PHP, so I've just it to be 10 years ¯\_(ツ)_/¯
 
The section that includes your splash code page can now have a conditional wrapped around it to check if the cookie exists, if it does then it's ignored.

<?php // check if displaySplash exists - show splash screen if not
  if( !isset($_COOKIE['displaySplash'] )): ?>
  <div class="splash fade-in">
    <h1 class="splash-title fade-in"><img src="img/logo.png" /></h1>
    <a href="#" class="splash-arrow fade-in">skip</a>
  </div>
<?php endif; ?>

I haven't tested any of this, and to be honest you would be better off explaining why this is bad to the client. Even clients that seem stubborn can come around if the negatives are outlined correctly.







0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users