Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

larsson719

Members
  • Joined

  • Last visited

  1. As I'm still new to codeigniter I was unaware of templates and I'm now doing some research, however, I'm still having a hard time grasping the concept. No worries though I'll just keep experimenting until it makes sense or I break my installation!
  2. My apologies if this method of calling controllers is absurd or common knowledge but I've recently started using frameworks to bear with me here. I'm working on the second version of a lightweight cms and this time I'm using a framework to help ease the workload a bit. Our aim with this cms is to keep it as simple as possible and installation is just to extract our cms into the website's root directory. A user's directory structure will mostly look as such: |-- images |-- css |-- js |-- cms <-- holds framework |-- application |-- system |-- index.php |-- index.php <-- call controller using URI segment Lets say the user wants to display a list of images uploaded using our cms. He would then call our controller using a URI-segment such as: http://localhost/controller/ from within index.php located in the root. We thought it would be most user-friendly to be able to use our cms' features without having to split the layout into MVC form. A working solution we have is to call the controllers using ajax but if javascript were to be disabled the website would be rendered utterly useless. Another suggestion was to use PHP cURL and I found this project on github which is a codeigniter library. The only problem is that we are trying to access codeigniter functions from OUTSIDE the framework so this might not be the best option. Lastly, I came across another PHP cURL question posted on stack overflow and it seems that PHP has a cURL library as well. What would be the proper solution to achieve our aim of easily using our cms without having the user dabble into any MVC-architecture. We used it to create the cms but the user should not have to learn how it works in order to use it.
  3.    WBC reacted to a post in a topic: Reddit users call to boycott GoDaddy...
  4. To those living within the US--remember to sign the online petitions such as: http://blacklists.eff.org http://sopastrike.com/strike http://americancensorship.org/ However, i think its all one big petition, but it doesn't hurt to sign them three times over! In addition, you can also call your state representatives and voice your opinion on this violation of the First Amendment.
  5. Let me be the first to say that is an awesome design! I love the use of typography (especially in the text bubble) and colors. The small picture of goku speaking to the user is great as well. My only problem with the design would be the text at the top of content that gives the user contact telephone number. I feel as if its a little bit too large and kind of doesn't fit the rest of the design due to its large size. Perhaps making it a tad smaller would help?
  6. Hello all. I'm designing a website for a local 2D Fine Arts artist and I would appreciate any tips/advice/critique of the design so far. I'm still wondering what I should do for the twitter feeds and for what will be the link to the shop. I'm debating whether it should be a static anchor linking to the shop or dynamically display newest item or something along those lines. What is working? What is not working? Is there anything in particular that bothers you about this design? Lastly, as motivation to become more familiar with mySQL and PHP I considered creating a lightweight content management system for this site. Out of that idea came another idea to try and make the system work on any artist's site I do, hence this is result: a standalone control panel. I've steered away from my regular minimalistic designs using mostly whites and grays, to a more colorful design using various colors (atleast that's what I tried to do) in order to appeal to the more experienced artistic eye of the users. So here it is and please let me know what's working or not working here Although the work displayed is still WIP any advice/critiques will be greatly appreciated as I continue to learn more about web design and development!
  7. Thanks for pointing out the PDO extension, jock, I was not aware that this existed but it seems like a more secure alternative. I will look into SSL as I'm planning on setting up a small e-commerce system as well--meaning there will be some sensitive data being sent through the system. Perhaps with SSL, it can make up for any lack of security I may have in the system... although I will try to patch up as many security holes as possible.
  8.    larsson719 reacted to a post in a topic: SESSION Hijacking
  9. Hello all. I'm a bit of a PHP noob, especially when it comes to security, so I've been lurking around the web looking at a bunch of articles that talk of some do's and dont's when considering making your PHP-driven website secure. Among the many security concerns there are two that call to my attention. Session Hijacking and SQL Insertion. I'm worried about the former because I pass some variables into a session, however, these variables do not contain any critical data, the only contain error messages. Here's a snippet: // Make sure the user selected atleast one item... if(empty($selection)) { $err[] = "ERROR - You did not select anything to delete."; $_SESSION["errors"] = $err; header("Location: img_del.php?doAction=delete&doCheck=failed"); exit(); } // Display Error Messages if($_GET["doCheck"] == "failed") { // Post errors, if any... echo "<p class=\"error\">"; foreach($_SESSION["errors"] as $key=>$e) { echo "* $e <br />"; } echo "</p>"; unset($_SESSION["errors"]); // unset the error variable... } I'm aware of some preventive measures that can be taken to avoid session hijacking, however, should I regenerate the session id even if the data contained in the session is non-critical? Can the snippet above be exploited in any way? As for the latter, SQL Injection, while searching the web for common security techniques I stumbled across a useful function that filters the input data from a form: /* This code filters harmful script code and escapes data of all POST data from the user submitted form. */ function filter($data) { $data = trim(htmlentities(strip_tags($data))); if(get_magic_quotes_gpc()) $data = stripslashes($data); $data = mysql_real_escape_string($data); return $data; } // Loop through input values and filter... foreach($_POST as $key => $value) { $data[$key] = filter($value); } Since the filter function is using mysql_real_escape_string to filter the data when querying the DB, I don't really take any other security measures afterwards. Is it bad practice to assign $data["input"] straight to a variable to be later used when querying the DB? Thanks in advance for any tips given!
  10.    larsson719 reacted to a post in a topic: Saving a PDF Print-Ready File
  11. Thanks for taking the time in replying to my topic. Unfortunately, I'm just about finished with this design and I've done it all on photoshop :[ I wish I looked into this before starting this project. I've looked around and I see that at this point, I would have to start from scratch if I were to transfer this design to illustrator. However, I have a question about this process. If I remove all my text from the design and convert to vector image, would illustrator have no problem opening that file? Because if so, I could just add the text using illustrator and viola! Problem solved :] Or, either way, would I have to start from scratch? PS: Assuming I would get the latest version of illustrator and I'm using anything later than Photoshop CS3
  12. Hello all. I'm fairly new to graphic designs so bare with me if my questions seem somewhat silly for those of you who have years of experience. I've created a menu design for a local dine-in restaurant. I've decided to create a bar-styled size for their menu so the size is (6in x 11in) and now that I'm done I've run across a problem of WHERE to print a custom size like this and how to save it so that the colors are kept optimal. (I've been using Photoshop and not Illustrator) I've done some research regarding optimization of color for print on some sites that do custom printing jobs and such; and I have gathered the following: Create the image using 300dpi, CYMK color preset from Photoshop, and ensure its 16-bit. Make sure you've accounted for the 'bleed' in your design, filling this area with any background colors or images. Ensure all important parts of your design are kept within the safe area. Possible designs featuring graphics or text should be saved as vector based PDFs. To set the correct color space for your PDF, click on the 'output' option shown on the left of your screen when you select the 'Adobe PDF/X-1a' preset. In the 'color' box, select 'Coated GRACoL 2006' from the destination dropdown. I figured, follow these simple steps and it should all go smoothly, unfortunately...that's not the case. I'm kind of confused on the many options that come when saving as a PDF such as: PDF/x1-a 2003 vs. PDF/x1-a 2001 Compression - Do I disable downsampling to keep the 300dpi setting? Color Conversion - Some guides advised to save in Coated GRACoL 2006; while others said to save in CYMK. Which is it? Summary - Why does it say that my 16bit image will be converted to 8bit. I know it is for compatibility purposes but what purpose does that serve if I'm trying to print it in 16bit? What format do you normally save your finished product in so that it is ready to be printed? Do you use the above settings or a variation of it or something entirely different? Please keep in mind that I only have photoshop to work with.... but if using illustrator would make this task hundreds of times easier then let me know. As a side note for experienced designers... do you know any online places that would print a custom size such as 6'' x 11'' or a place that creates booklets such as this for that same size?
  13. Thanks for the input guys. I wanted to use a full screen background actually but I figured using an HP images would probably get me into trouble so I didn't bother now I'm just trying to figure out what to do once the timer hits 0. Perhaps a link to
  14. Hey all. My girlfriend has been pretty excited for the latest and final harry potter movie coming out. Therefore, as a small exercise I decided to make a small site to countdown to the premier lol theHALLOWS Ahhhh, dot.tk, haven't used that in years :] Anyway what do you guys think of it in terms of a countdown site. I know its small and not much to judge but I'm pretty happy with it... Now the real reason I'm here is I would like to know if everything is working properly because I used @font-face for the first time and it worked on my pc (firefox 5.0b) and my gf's (mac-firefox 3.x.x) but I'm not sure if it'll work on an older OS or older browser. I also managed to get a facebook "like" widget on there without actually having a developer id and it works fine on PC but for some reason on MAC it isn't loading... anyone have better experience with this? Would it be because I don't have a developer id? Thanks in advanced for any critiques and input!
  15. I'm not sure if you can have any c++ applets or something similar to Java has but c++ is sometimes used on sites.....in a sense. Hip-hop converts your PHP source code into C++ in a "semantically equivalent manner". Although this could be web-related its not really necessary in most sitations its mostly used by companies who receive a lot of web traffic and have vast php infrastructures.... Yep yep...developing PHP in my home environment has helped me catch on quicker when trying to learn other programming languages. Although each language is very unique from the others you see similar things used such as arrays, while loops, classes, methods, etc..
  16. haha i like how u said that. So yea, simple logic mistake, figures. So much to learn its like learning another language with so many reserved words, classes, and functions i've yet to fully understand.... Thanks a lot man. I'll update you when i test out. Got caught up in some other business and i haven't been able to get to it yet, but im pretty positive it will populate now :]
  17. (Warning: You are now approaching a wall of text. For a TL;DR detour scroll to the bottom of my post! :]) Hello all. I wasn't exactly sure where to make a topic for the problem that I'm having. I figured I'd put it in this category since what I'm doing is not web-related, however, its a language I'm sure a lot of users on here are familiar with. Okay so I'm to make a blackjack program for my java dev class. Its rather simple (as i'm still learning) and can pretty much be summed up in the following steps: Assign two cards to the dealer. One will be shown, the other will not. Player will pick two cards (randomly chosen, of course) The player has the option of adding an additional four cards to his hand (player can have max 6 cards in hand) Total up dealer's/player's hands and determine a winner/loser I plan on setting up a handful of arrays with the purpose of holding dynamic values such as: Dealer's score Player's score Dealer's hand Player's hand In addition to these arrays, there will be an array that will work as a "deck", in other words, it will hold all the cards values and the path to their image location. Unfortunately, this is where I am stuck. My Problem I have setup a class called cards.java that is used to populate the array. Another class called hits.java will randomly generate a number that I will then use to point to an index position on the "deck" array. My main.java class wraps it all up and takes the value from hits.java and adds it to the frame. At least, that is how it was supposed to go according to plan. I've pretty much pinpointed the problem; which to me is somewhere in my cards.java class: public class cards { // Create a 2D Array, 51x51. public String[][] deck = new String[51][51]; // Create instance of main class. private main mi = new main(); // Run Method. public void runCards() { // Populate the array. for(int i = 0; i < deck.length; i++) { // Aces. for(int a = 0; a == 3; a++) { deck[a][0] = "1"; deck[a][1] = mi.home + "/My Documents/NetBeansProjects/CCP Blackjack/src/deck/a" + a + ".png"; } // King, Queen, Jack, Ten. for(int b = 4; b == 19; b++) { deck[b][0] = "10"; deck[b][1] = mi.home + "/My Documents/NetBeansProjects/CCP Blackjack/src/deck/b" + b + ".png"; } // Nine. for(int c = 20; c == 23; c++) { deck[c][0] = "9"; deck[c][1] = mi.home + "/My Documents/NetBeansProjects/CCP Blackjack/src/deck/c" + c + ".png"; } // Eight. for(int d = 24; d == 27; d++) { deck[d][0] = "8"; deck[d][1] = mi.home + "/My Documents/NetBeansProjects/CCP Blackjack/src/deck/d" + d + ".png"; } // And so on........... } } } I'll also post my hits.java class, whose purpose is to randomly generate a number and point to that index location in my array: // Import necessary classes. import java.util.Random; public class hits { // Create random object. Random rand = new Random(); // Declare variables. int card; String cardVal, cardPic; // Instantiate the needed classes. main mi = new main(); cards ci = new cards(); // Constructor for the class. public hits() { // Randomly generate a number (0 - 51). card = rand.nextInt(10); // Populate the array. ci.runCards(); // Assign the cards according to the num. generated. cardVal = ci.deck[card][0]; cardPic = ci.deck[card][1]; } } Take note of the bottom lines: cardVal = ci.deck[card][0]; I've changed that to: cardVal = ci.deck[0][0]; In order to see if my array was even populated and nothing displayed. When I changed that to a regular string: cardVal = "hello"; Just to see if "cardVal" was even displaying in my JLabel........ it worked. TL;DR: Take a look at my for-loop. For some reason my array is not populating...... what am I doing wrong!! Thanks in advance for any help given. :]

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.