Jump to content

DizzyDan

Members
  • Content Count

    261
  • Joined

  • Last visited

Community Reputation

10 Good

About DizzyDan

  • Rank
    Member
  • Birthday 08/30/1985

Previous Fields

  • Languages
    HTML, CSS, jQuery

Profile Information

  • Location
    New York
  • Interests
    Web Development, Music.

Recent Profile Visitors

6,002 profile views
  1. Just to update this: So it seems this was a more complicated problem so I had to work this out in smaller pieces. I was getting a CORS error because I was requesting the json from a different domain with jQuery, I learned that you can't do that... With a sprinkle of PHP I was able to get the json data and feed it to a file on my server, so I guess that's like using my server as a proxy. This seemed to work. I removed the click function and created a form where the user can enter their zipcode This is probably sloppy but it did work! index.php <!DOCT
  2. I am trying to build a basic tool to display someones congress representative via zipcode. The API that I am trying to use is offered for free via: https://whoismyrepresentative.com The link to get the data via zipcode is: https://whoismyrepresentative.com/getall_mems.php?zip=31023 It can also be formatted for json like this: https://whoismyrepresentative.com/getall_mems.php?zip=31023&output=json I have read a ton of articles on how to display this data but the trouble I am having is getting the data to show up at all. My first attempt was based off w3schools exam
  3. Originally I thought it might have been a jQuery issue but this might make more sense in the CSS thread.
  4. Like to the body tag? body{ overflow-x: hidden; } This seems to do the trick. Edit: Just wanted to clarify I had to also change .push-open from position:fixed; to position: absolute; Edit II: I also have to add a to .menu incase the menu height was taller then the window: .menu{ position: fixed; height: 100%; overflow-y: scroll; }
  5. Project Code: https://codepen.io/Digitango/pen/VzyZyO Project Description: I created a pretty basic push menu using jQuery. What I want to achieve is to click the menu bars, push the main-content over and display the menu. Then close the menu when you either click the menu bars again, click the close icon or click anywhere off the menu. So far I handled all of this successfully, however, one thing I don't like is if you scroll down on the main-content, then click the menu bars the main-content goes back to the top. It does this because I use toggleClass to change to 'position: f
  6. Looks normal to me, can you provide a screenshot of the issue?
  7. OK figured it out! The starting navigation #sticky-header Is a block level element, which is all fine and dandy till you scroll past the menu and I add the class .stuck With the style of position: fixed; Now I want it to be fixed so the menu stays with the user as they scroll BUT fixed makes it lose the block level element causing the space change that made it not line up correctly. Sooooo, now for the solution! I added float: left; To my starting styles for #sticky-header AND added padding-top: 140px; To the next element to compensa
  8. Do you have a live example? You can use Chromes inspector tool (CTRL + SHIFT + I) to see which class is working and which is crossed out.
  9. So I did try that but when I add: #why-amac{ margin-top: 100px; } And click that same "Why AMAC" link the header still covers that same area but if I scroll up the space will be there.
  10. I am developing a single page website that scrolls to each section when selected, live example: http://sandbox.digitango.com/ The issue I am having is with the sticky header, when you click the first link "Why AMAC" it will send you to the first section BUT when the header changes to fixed position it covers the content. I searched google reading a ton of articles but nothing seemed to address this issue, maybe I am missing the correct term for what my issue is. Is there any solution you know of that can fill the gap for when the header changes to fixed? - Image one - what
  11. Ahh that worked, forgot about that sneaky 's' # Force WWW RewriteCond %{HTTP_HOST} !^www\.creativejuicesmusic\.com [NC] RewriteRule (.*) https://www.creativejuicesmusic.com/$1 [R=301,L] Thanks for all the help!
  12. OK so I placed this at the very top of the htaccess file # Force WWW RewriteCond %{HTTP_HOST} !^www\.creativejuicesmusic\.com [NC] RewriteRule (.*) http://www.creativejuicesmusic.com/$1 [R=301,L] # Force HTTPS RewriteEngine On RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L] But now in google page speed insights it throws this at me: I thought doing this via htaccess was the correct kind of fix for this.
  13. This code works for the www but for some reason when this code is applied and you enter creativejuicesmusic.com int the web browser it takes you to: http://www.creativejuicesmusic.com/wp-content/cache/page_enhanced/creativejuicesmusic.com/_index.html_gzip instead of http://www.creativejuicesmusic.com So something funky is going on. I moved the gzip code to go after the wordress code and everything seems to check out.
  14. I am using WordPress and trying to redirect to www. I added the line below to my htaccess file and the redirect works but it send the URL here: http://www.creativejuicesmusic.com/wp-content/cache/page_enhanced/creativejuicesmusic.com/_index.html_gzip RewriteCond %{HTTP_HOST} ^creativejuicesmusic.com [nocase] RewriteRule ^(.*) http://www.creativejuicesmusic.com/$1 [last,redirect=301] This is my full htaccess file # BEGIN W3TC Browser Cache <IfModule mod_deflate.c> <IfModule mod_filter.c> AddOutputFilterByType DEFLATE text/css text/x-component application/x-javas
  15. So the script would be for creating the XML Sitemap for the 1 million records? Do you know of a good resource for a tutorial or examples of some XML sitemaps for a database?
×
×
  • Create New...