Search Results

Search found 512 results on 21 pages for 'luke burns'.

Page 4/21 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Mouse click firing twice

    - by Luke
    I have recently switched to XUbuntu (14.04) and I have noticed that sometimes a mouse click is fired twice. E.g. I CTRL click a link and two tabs with the same content are opened in my browser. It's not behaviour I can reproduce consistently and seems to be random (to me). I also don't know of a good way to inspect the behaviour properly for debugging purposes. I have checked the double click time setting but this doesn't seem to have any impact on this. I also run XUbuntu (13.10) in a VM on my MacBook Air and this behaviour seems to absent there. At this point in time I can't really tell if this is related to the distribution or the fact that it runs in a VM. Any insights greatly appreciated.

    Read the article

  • Starting application in same window with XFCE4 Terminal and i3

    - by Luke
    Since recently I'm enjoying the i3 tiled window manager. I did install the XFCE4 Terminal since it gives greater control over my terminal look and feel however but I have noticed an issue with starting GUI based applications. When I execute a GUI based application I want it take over the current terminal window. To do this I use exec, as in: exec eclipse This will open a new window and leave the terminal I started the application in open as well. In normal circumstances this is not much of a problem since I can easily do an Alt-W on the GUI app's window. However, for some applications, like a file manager, it is necessary to open in the same window. How can I make GUI application open in the same window rather than opening a new one?

    Read the article

  • Implementing Camera Zoom in a 2D Engine

    - by Luke
    I'm currently trying to implement camera scaling/zoom in my 2D Engine. Normally I calculate the Sprite's drawing size and position similar to this pseudo code: render() { var x = sprite.x; var y = sprite.y; var sizeX = sprite.width * sprite.scaleX; // width of the sprite on the screen var sizeY = sprite.height * sprite.scaleY; // height of the sprite on the screen } To implement the scaling i changed the code to this: class Camera { var scaleX; var scaleY; var zoom; var finalScaleX; // = scaleX * zoom var finalScaleY; // = scaleY * zoom } render() { var x = sprite.x * Camera.finalScaleX; var y = sprite.y * Camera.finalScaleY; var sizeX = sprite.width * sprite.scaleX * Camera.finalScaleX; var sizeY = sprite.height * sprite.scaleY * Camera.finalScaleY; } The problem is that when the zoom is smaller than 1.0 all sprites are moved toward the top-left corner of the screen. This is expected when looking at the code but i want the camera to zoom on the center of the screen. Any tips on how to do that are welcome. :)

    Read the article

  • Using foldr to append two lists together (Haskell)

    - by Luke Murphy
    I have been given the following question as part of a college assignment. Due to the module being very short, we are using only a subset of Haskell, without any of the syntactic sugar or idiomatic shortcuts....I must write: append xs ys : The list formed by joining the lists xs and ys, in that order append (5:8:3:[]) (4:7:[]) => 5:8:3:4:7:[] I understand the concept of how foldr works, but I am only starting off in Functional programming. I managed to write the following working solution (hidden for the benefit of others in my class...) : However, I just can't for the life of me, explain what the hell is going on!? I wrote it by just fiddling around in the interpreter, for example, the following line : foldr (\x -> \y -> x:y) [] (2:3:4:[]) which returned [2:3:4] , which led me to try, foldr (\x -> \y -> x:y) (2:3:4:[]) (5:6:7:[]) which returned [5,6,7,2,3,4] so I worked it out from there. I came to the correct solution through guess work and a bit of luck... I am working from the following definition of foldr: foldr = \f -> \s -> \xs -> if null xs then s else f (head xs) (foldr f s (tail xs) ) Can someone baby step me through my correct solution? I can't seem to get it....I already have scoured the web, and also read a bunch of SE threads, such as How foldr works

    Read the article

  • Protecting a webpage with an authentication form

    - by Luke
    I have created an employee webpage with a lot of company info, links, etc., but I want to protect the page because it contains some confidential company information. I am running IIS7.5 on Windows Server 2008 R2, and I already have the site setup as a normal, non-protected site. I want all active directory users to have access to the site. This is not an intranet site, it is exposed to the internet. I tried setting it up using Windows Authentication, but I had problems with multiple login prompts, etc. I just want a simple form for users to enter their credentials and have access to the site, and I need it to query the AD for login. I've searched the web for a guide on this, but I can't seem to find one that fits my situation. This is not a Web App. It is just a simple html site. Does anyone have any suggestions or a link to a guide on this? Thanks so much! -LB

    Read the article

  • What techniques can I use to render very large numbers of objects more efficiently in OpenGL?

    - by Luke
    You can think of my application as drawing a very large ball-and-stick diagram (or graph). At times, this graph can get very large, where the number of elements even outnumbers the pixels on the screen. Currently I am simply passing all of my textures (as GL_POINTS) and lines to the graphics card using VBO's. When the number of elements outnumbers the number of pixels, is this the most efficient way to do this? Or should I do some calculations on the CPU side before handing everything over to the GPU? If it matters, I do use GL_DEPTH_TEST and GL_ALPHA_TEST. I do some alpha blending, but probably not enough to make a huge performance difference. My scene can be static at times, but the user has control over a typical arc-ball camera and can pan, rotate, or zoom. It is during these operations that performance degradation is noticeable.

    Read the article

  • NerdDinner form validation DataAnnotations ERROR in MVC2 when a form field is left blank.

    - by Edward Burns
    Platform: Windows 7 Ultimate IDE: Visual Studio 2010 Ultimate Web Environment: ASP.NET MVC 2 Database: SQL Server 2008 R2 Express Data Access: Entity Framework 4 Form Validation: DataAnnotations Sample App: NerdDinner from Wrox Pro ASP.NET MVC 2 Book: Wrox Professional MVC 2 Problem with Chapter 1 - Section: "Integrating Validation and Business Rule Logic with Model Classes" (pages 33 to 35) ERROR Synopsis: NerdDinner form validation ERROR with DataAnnotations and db nulls. DataAnnotations in sample code does not work when the database fields are set to not allow nulls. ERROR occurs with the code from the book and with the sample code downloaded from codeplex. Help! I'm really frustrated by this!! I can't believe something so simple just doesn't work??? Steps to reproduce ERROR: Set Database fields to not allow NULLs (See Picture) Set NerdDinnerEntityModel Dinner class fields' Nullable property to false (See Picture) Add DataAnnotations for Dinner_Validation class (CODE A) Create Dinner repository class (CODE B) Add CREATE action to DinnerController (CODE C) This is blank form before posting (See Picture) This null ERROR occurs when posting a blank form which should be intercepted by the Dinner_Validation class DataAnnotations. Note ERROR message says that "This property cannot be set to a null value. WTH??? (See Picture) The next ERROR occurs during the edit process. Here is the Edit controller action (CODE D) This is the "Edit" form with intentionally wrong input to test Dinner Validation DataAnnotations (See Picture) The ERROR occurs again when posting the edit form with blank form fields. The post request should be intercepted by the Dinner_Validation class DataAnnotations. Same null entry error. WTH??? (See Picture) See screen shots at: http://www.intermedia4web.com/temp/nerdDinner/StackOverflowNerdDinnerQuestionshort.png CODE A: [MetadataType(typeof(Dinner_Validation))] public partial class Dinner { } [Bind(Include = "Title, EventDate, Description, Address, Country, ContactPhone, Latitude, Longitude")] public class Dinner_Validation { [Required(ErrorMessage = "Title is required")] [StringLength(50, ErrorMessage = "Title may not be longer than 50 characters")] public string Title { get; set; } [Required(ErrorMessage = "Description is required")] [StringLength(265, ErrorMessage = "Description must be 256 characters or less")] public string Description { get; set; } [Required(ErrorMessage="Event date is required")] public DateTime EventDate { get; set; } [Required(ErrorMessage = "Address is required")] public string Address { get; set; } [Required(ErrorMessage = "Country is required")] public string Country { get; set; } [Required(ErrorMessage = "Contact phone is required")] public string ContactPhone { get; set; } [Required(ErrorMessage = "Latitude is required")] public double Latitude { get; set; } [Required(ErrorMessage = "Longitude is required")] public double Longitude { get; set; } } CODE B: public class DinnerRepository { private NerdDinnerEntities _NerdDinnerEntity = new NerdDinnerEntities(); // Query Method public IQueryable<Dinner> FindAllDinners() { return _NerdDinnerEntity.Dinners; } // Query Method public IQueryable<Dinner> FindUpcomingDinners() { return from dinner in _NerdDinnerEntity.Dinners where dinner.EventDate > DateTime.Now orderby dinner.EventDate select dinner; } // Query Method public Dinner GetDinner(int id) { return _NerdDinnerEntity.Dinners.FirstOrDefault(d => d.DinnerID == id); } // Insert Method public void Add(Dinner dinner) { _NerdDinnerEntity.Dinners.AddObject(dinner); } // Delete Method public void Delete(Dinner dinner) { foreach (var rsvp in dinner.RSVPs) { _NerdDinnerEntity.RSVPs.DeleteObject(rsvp); } _NerdDinnerEntity.Dinners.DeleteObject(dinner); } // Persistence Method public void Save() { _NerdDinnerEntity.SaveChanges(); } } CODE C: // ************************************** // GET: /Dinners/Create/ // ************************************** public ActionResult Create() { Dinner dinner = new Dinner() { EventDate = DateTime.Now.AddDays(7) }; return View(dinner); } // ************************************** // POST: /Dinners/Create/ // ************************************** [HttpPost] public ActionResult Create(Dinner dinner) { if (ModelState.IsValid) { dinner.HostedBy = "The Code Dude"; _dinnerRepository.Add(dinner); _dinnerRepository.Save(); return RedirectToAction("Details", new { id = dinner.DinnerID }); } else { return View(dinner); } } CODE D: // ************************************** // GET: /Dinners/Edit/{id} // ************************************** public ActionResult Edit(int id) { Dinner dinner = _dinnerRepository.GetDinner(id); return View(dinner); } // ************************************** // POST: /Dinners/Edit/{id} // ************************************** [HttpPost] public ActionResult Edit(int id, FormCollection formValues) { Dinner dinner = _dinnerRepository.GetDinner(id); if (TryUpdateModel(dinner)){ _dinnerRepository.Save(); return RedirectToAction("Details", new { id=dinner.DinnerID }); } return View(dinner); } I have sent Wrox and one of the authors a request for help but have not heard back from anyone. Readers of the book cannot even continue to finish the rest of chapter 1 because of these errors. Even if I download the latest build from Codeplex, it still has the same errors. Can someone please help me and tell me what needs to be fixed? Thanks - Ed.

    Read the article

  • Rails, RSpec and Webrat: Expected output matches rendered output but still getting error in view spe

    - by Anthony Burns
    Hello all, I've just gotten started using BDD with RSpec/Cucumber/Webrat and Rails and I've run into some frustration trying to get my view spec to pass. First of all, I am running Ruby 1.9.1p129 with Rails 2.3.2, RSpec and RSpec-Rails 1.2.6, Cucumber 0.3.11, and Webrat 0.4.4. Here is the code relevant to my question config/routes.rb: map.b_posts 'backend/posts', :controller => 'backend/posts', :action => 'backend_index', :conditions => { :method => :get } map.connect 'backend/posts', :controller => 'backend/posts', :action => 'create', :conditions => { :method => :post } views/backend/posts/create.html.erb: <% form_tag do %> <% end %> *spec/views/backend/posts/create.html.erb_spec.rb:* describe "backend/posts/create.html.erb" do it "should render a form to create a post" do render "backend/posts/create.html.erb" response.should have_selector("form", :method => 'post', :action => b_posts_path) do |form| # Nothing here yet. end end end Here is the relevant part of the output when I run script/spec: 'backend/posts/create.html.erb should render a form to create a post' FAILED expected following output to contain a <form method='post' action='/backend/posts'/> tag: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"> <html><body><form action="/backend/posts" method="post"> </form></body></html> It would appear to me that what have_selector is looking for is exactly what the template generates, yet the example still fails. I am very much looking forward to seeing my error (because I have a feeling it is my error). Any help is much appreciated!

    Read the article

  • jQuery UI blind effect - reveal from bottom

    - by ronnie burns
    This could be really obvious and I'm completely missing it. I've searched for hours and can't seem to find a way to, using jQuery, reveal a hidden div from the bottom up. What I am trying to achieve is exactly as in the following link, but in reverse: http://jqueryui.com/demos/show/ I can slide a div from the bottom to the top, but this reveals itself as it moves, rather than being 'masked' in. Like I said, this could (should?) be really obvious and I'm not seeing it, but I've been looking for ages and can't find a solution to this relatively simple problem. Thanks, Ronnie

    Read the article

  • jQuery AJAX with two domains

    - by Andrew Burns
    OK here is the situation: I have an externally hosted CMS which works great for 99% of our needs. However on the more advanced things I inject my own CSS+JS and do magic. The problem I am running into is loading a simple HTML page from jQuery.ajax() calls. It appears to work in the sense that no warnings or errors are thrown; however in my success handler (which IS ran), the response is blank! I have been scratching my head for the whole morning trying to figure this out and the only thing I can think of is that is has something to do with the cross domain issue (even though it appears to work). Injected JavaScript: $(document).ready(function() { doui(); }); function doui() { $.ajax({ url: 'http://apps.natronacounty-wy.gov/css/feecalc/ui.htm', cache: false, success: ajax_createUI, charset: "utf-8", error: function(e) { alert(e); } }); } function ajax_createUI(data, textStatus) { alert(data); $("#ajax-content").html(data); } My ajax_createUI() success handler is called and textStatus is "success"; however data is empty. This JS file resides @ http://apps.natronacounty-wy.gov/css/js/feecalc.js however the CMS website (which gets the JS injected into it) resides @ http://www.natronacounty-wy.gov/ Am I just being stupid or is it a bug that it looks like it should be working but isn't?

    Read the article

  • For Loop help In a Hash Cracker Homework.

    - by aaron burns
    On the homework I am working on we are making a hash cracker. I am implementing it so as to have my cracker. java call worker.java. Worker.java implements Runnable. Worker is to take the start and end of a list of char, the hash it is to crack, and the max length of the password that made the hash. I know I want to do a loop in run() BUT I cannot think of how I would do it so it would go to the given max pasword length. I have posted the code I have so far. Any directions or areas I should look into.... I thought there was a way to do this with a certain way to write the loop but I don't know or can't find the correct syntax. Oh.. also. In main I divide up so x amount of threads can be chosen and I know that as of write now it only works for an even number of the 40 possible char given. package HashCracker; import java.util.*; import java.security.MessageDigest; import java.security.NoSuchAlgorithmException; public class Cracker { // Array of chars used to produce strings public static final char[] CHARS = "abcdefghijklmnopqrstuvwxyz0123456789.,-!".toCharArray(); public static final int numOfChar=40; /* Given a byte[] array, produces a hex String, such as "234a6f". with 2 chars for each byte in the array. (provided code) */ public static String hexToString(byte[] bytes) { StringBuffer buff = new StringBuffer(); for (int i=0; i<bytes.length; i++) { int val = bytes[i]; val = val & 0xff; // remove higher bits, sign if (val<16) buff.append('0'); // leading 0 buff.append(Integer.toString(val, 16)); } return buff.toString(); } /* Given a string of hex byte values such as "24a26f", creates a byte[] array of those values, one byte value -128..127 for each 2 chars. (provided code) */ public static byte[] hexToArray(String hex) { byte[] result = new byte[hex.length()/2]; for (int i=0; i<hex.length(); i+=2) { result[i/2] = (byte) Integer.parseInt(hex.substring(i, i+2), 16); } return result; } public static void main(String args[]) throws NoSuchAlgorithmException { if(args.length==1)//Hash Maker { //create a byte array , meassage digestand put password into it //and get out a hash value printed to the screen using provided methods. byte[] myByteArray=args[0].getBytes(); MessageDigest hasher=MessageDigest.getInstance("SHA-1"); hasher.update(myByteArray); byte[] digestedByte=hasher.digest(); String hashValue=Cracker.hexToString(digestedByte); System.out.println(hashValue); } else//Hash Cracker { ArrayList<Thread> myRunnables=new ArrayList<Thread>(); int numOfThreads = Integer.parseInt(args[2]); int charPerThread=Cracker.numOfChar/numOfThreads; int start=0; int end=charPerThread-1; for(int i=0; i<numOfThreads; i++) { //creates, stores and starts threads. Runnable tempWorker=new Worker(start, end, args[1], Integer.parseInt(args[1])); Thread temp=new Thread(tempWorker); myRunnables.add(temp); temp.start(); start=end+1; end=end+charPerThread; } } } import java.util.*; public class Worker implements Runnable{ private int charStart; private int charEnd; private String Hash2Crack; private int maxLength; public Worker(int start, int end, String hashValue, int maxPWlength) { charStart=start; charEnd=end; Hash2Crack=hashValue; maxLength=maxPWlength; } public void run() { byte[] myHash2Crack_=Cracker.hexToArray(Hash2Crack); for(int i=charStart; i<charEnd+1; i++) { Cracker.numOfChar[i]////// this is where I am stuck. } } }

    Read the article

  • Uncatchable errors in node.js

    - by Peter Burns
    So I'm trying to write a simple TCP socket server that broadcasts information to all connected clients. So when a user connects, they get added to the list of clients, and when the stream emits the close event, they get removed from the client list. This works well, except that sometimes I'm sending a message just as a user disconnects. I've tried wrapping stream.write() in a try/catch block, but no luck. It seems like the error is uncatchable.

    Read the article

  • I'm trying to run a command using WMI.

    - by MIchael Burns
    This is my code: a button is clicked and the text in a textbox is taken for the remotePC. I can run it locally but when I try to run it remotely it will not work, I think it has something to do with using WMI to run a shared file? public void IPXFER(string RemotePC) { object[] theProcessToRun = { @"\\network-share\ipxfer\ipxfer.exe -s corp-trend -p 1234 -m 1 -c 12345" }; ConnectionOptions theConnection = new ConnectionOptions(); theConnection.Impersonation = ImpersonationLevel.Impersonate; theConnection.EnablePrivileges = true; ManagementScope theScope = new ManagementScope("\\\\" + RemotePC + "\\root\\cimv2", theConnection); ManagementClass theClass = new ManagementClass(theScope, new ManagementPath("Win32_Process"), new ObjectGetOptions()); theClass.InvokeMethod("Create", theProcessToRun); }

    Read the article

  • How to query an .NET assembly's required framework (not CLR) version?

    - by Bonfire Burns
    Hi, we are using some kind of plug-in architecture in one of our products (based on .NET). We have to consider our customers or even 3rd party devs writing plug-ins for the product. The plug-ins will be .NET assemblies that are loaded by our product at run-time. We have no control about the quality or capabilities of the external plug-ins (apart from checking whether they implement the correct interfaces). So we need to implement some kind of safety check while loading the plug-ins to make sure that our product (and the hosting environment) can actually host the plug-in or deliver a meaningful error message ("The plug-in your are loading needs .NET version 42.42 - the hosting system is only on version 33.33."). Ideally the plug-ins would do this check internally, but our experience regarding their competence is so-so and in any case our product will get the blame, so we want to make sure that this "just works". Requiring the plug-in developers to provide the info in the metadata or to explicitly provide the information in the interface is considered "too complicated". I know about the Assembly.ImageRuntimeVersion property. But to my knowledge this tells me only the needed CLR version, not the framework version. And I don't want to check all of the assembly's dependencies and match them against a table of "framework version vs. available assemblies". Do you have any ideas how to solve this in a simple and maintainable fashion? Thanks & regards, Bon

    Read the article

  • Download and Share Visual Studio Color Schemes

    - by ScottGu
    As developers we often spend a large part of our day staring at code within Visual Studio.  If you are like me, after awhile the default VS text color scheme starts to get a little boring. The good news is that Visual Studio allows you to completely customize the editor background and text colors to whatever you want – allowing you to tweak them to create the experience that is “just right” for your eyes and personality.  You can then optionally export/import your color scheme preferences to an XML file via the Tools->Import and Export Settings menu command. [In addition to blogging, I am also now using Twitter for quick updates and to share links. Follow me at: twitter.com/scottgu] New website that makes it easy to download and share VS color schemes Luke Sampson launched the http://studiostyles.info/ site a week ago (built using ASP.NET MVC 2, ASP.NET 4 and VS 2010). Studiostyles.info enables you to easily browse and download Visual Studio color schemes that others have already created.  The color schemes work for both VS 2008 and VS 2010 (all versions – including the free VS express editions): Color schemes are sorted by popularity and voting (you can vote on whether you find each “hot or not”).  You can click any of the schemes to see screen-shots of it in use for common coding scenarios.  You can then download the color settings for either VS 2010 or VS 2008: You can also optionally upload color schemes of your own if you have a good one you want to share with others.  If you haven’t visited it yet – check it out: http://studiostyles.info/  And thank you Luke Sampson for building it! Hope this helps, Scott

    Read the article

  • Flame Experiments Aboard the ISS Yield Surprising Results

    - by Jason Fitzpatrick
    Recent flame-based experiments aboard the International Space Station yielded results scientists simply thought couldn’t happen–combustion in microgravity is a curious thing. Smithsonian magazine reports on the findings: Here on Earth, when a flame burns, it heats the surrounding atmosphere, causing the air to expand and become less dense. The pull of gravity draws colder, denser air down to the base of the flame, displacing the hot air, which rises. This convection process feeds fresh oxygen to the fire, which burns until it runs out of fuel. The upward flow of air is what gives a flame its teardrop shape and causes it to flicker. But odd things happen in space, where gravity loses its grip on solids, liquids and gases. Without gravity, hot air expands but doesn’t move upward. The flame persists because of the diffusion of oxygen, with random oxygen molecules drifting into the fire. Absent the upward flow of hot air, fires in microgravity are dome-shaped or spherical—and sluggish, thanks to meager oxygen flow. “If you ignite a piece of paper in microgravity, the fire will just slowly creep along from one end to the other,” says Dietrich. “Astronauts are all very excited to do our experiments because space fires really do look quite alien.” Hit up the link below for the full article including how NASA is applying the findings. Why Does 64-Bit Windows Need a Separate “Program Files (x86)” Folder? Why Your Android Phone Isn’t Getting Operating System Updates and What You Can Do About It How To Delete, Move, or Rename Locked Files in Windows

    Read the article

  • Django CMS - not able to upload images through cmsplugin_filer_image

    - by Luke
    i have a problem with a local installation on django cms 2.3.3: i've installed it trough pip, in a separated virtualenv. next i followed the tutorial for settings.py configuration, i started the server. Then in the admin i created an page (home), and i've tried to add an image in the placeholder through the cmsplugin_filer_image, but the upload seems that doesn't work. here's my settings.py: # Django settings for cms1 project. # -*- coding: utf-8 -*- import os gettext = lambda s: s PROJECT_PATH = os.path.abspath(os.path.dirname(__file__)) DEBUG = True TEMPLATE_DEBUG = DEBUG ADMINS = ( # ('Your Name', '[email protected]'), ) MANAGERS = ADMINS DATABASES = { 'default': { 'ENGINE': 'django.db.backends.postgresql_psycopg2', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'. 'NAME': 'cms1', # Or path to database file if using sqlite3. 'USER': 'cms', # Not used with sqlite3. 'PASSWORD': 'cms', # Not used with sqlite3. 'HOST': '', # Set to empty string for localhost. Not used with sqlite3. 'PORT': '', # Set to empty string for default. Not used with sqlite3. } } # Local time zone for this installation. Choices can be found here: # http://en.wikipedia.org/wiki/List_of_tz_zones_by_name # although not all choices may be available on all operating systems. # In a Windows environment this must be set to your system time zone. TIME_ZONE = 'Europe/Rome' # Language code for this installation. All choices can be found here: # http://www.i18nguy.com/unicode/language-identifiers.html LANGUAGE_CODE = 'it-it' SITE_ID = 1 # If you set this to False, Django will make some optimizations so as not # to load the internationalization machinery. USE_I18N = True # If you set this to False, Django will not format dates, numbers and # calendars according to the current locale. USE_L10N = True # If you set this to False, Django will not use timezone-aware datetimes. USE_TZ = True # Absolute filesystem path to the directory that will hold user-uploaded files. # Example: "/home/media/media.lawrence.com/media/" MEDIA_ROOT = os.path.join(PROJECT_PATH, "media") # URL that handles the media served from MEDIA_ROOT. Make sure to use a # trailing slash. # Examples: "http://media.lawrence.com/media/", "http://example.com/media/" MEDIA_URL = '/media/' # Absolute path to the directory static files should be collected to. # Don't put anything in this directory yourself; store your static files # in apps' "static/" subdirectories and in STATICFILES_DIRS. # Example: "/home/media/media.lawrence.com/static/" STATIC_ROOT = os.path.join(PROJECT_PATH, "static") STATIC_URL = "/static/" # Additional locations of static files STATICFILES_DIRS = ( os.path.join(PROJECT_PATH, "static_auto"), # Put strings here, like "/home/html/static" or "C:/www/django/static". # Always use forward slashes, even on Windows. # Don't forget to use absolute paths, not relative paths. ) # List of finder classes that know how to find static files in # various locations. STATICFILES_FINDERS = ( 'django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder', # 'django.contrib.staticfiles.finders.DefaultStorageFinder', ) # Make this unique, and don't share it with anybody. SECRET_KEY = '^c2q3d8w)f#gk%5i)(#i*lwt%lm-!2=(*1d!1cf+rg&amp;-hqi_9u' # List of callables that know how to import templates from various sources. TEMPLATE_LOADERS = ( 'django.template.loaders.filesystem.Loader', 'django.template.loaders.app_directories.Loader', # 'django.template.loaders.eggs.Loader', ) MIDDLEWARE_CLASSES = ( 'django.middleware.common.CommonMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'cms.middleware.multilingual.MultilingualURLMiddleware', 'cms.middleware.page.CurrentPageMiddleware', 'cms.middleware.user.CurrentUserMiddleware', 'cms.middleware.toolbar.ToolbarMiddleware', # Uncomment the next line for simple clickjacking protection: # 'django.middleware.clickjacking.XFrameOptionsMiddleware', ) ROOT_URLCONF = 'cms1.urls' # Python dotted path to the WSGI application used by Django's runserver. WSGI_APPLICATION = 'cms1.wsgi.application' TEMPLATE_DIRS = ( os.path.join(PROJECT_PATH, "templates"), # Put strings here, like "/home/html/django_templates" or "C:/www/django/templates". # Always use forward slashes, even on Windows. # Don't forget to use absolute paths, not relative paths. ) CMS_TEMPLATES = ( ('template_1.html', 'Template One'), ('template_2.html', 'Template Two'), ) TEMPLATE_CONTEXT_PROCESSORS = ( 'django.contrib.auth.context_processors.auth', 'django.core.context_processors.i18n', 'django.core.context_processors.request', 'django.core.context_processors.media', 'django.core.context_processors.static', 'cms.context_processors.media', 'sekizai.context_processors.sekizai', ) LANGUAGES = [ ('it', 'Italiano'), ('en', 'English'), ] INSTALLED_APPS = ( 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.sites', 'django.contrib.messages', 'django.contrib.staticfiles', 'cms', #django CMS itself 'mptt', #utilities for implementing a modified pre-order traversal tree 'menus', #helper for model independent hierarchical website navigation 'south', #intelligent schema and data migrations 'sekizai', #for javascript and css management #'cms.plugins.file', 'cms.plugins.flash', 'cms.plugins.googlemap', 'cms.plugins.link', #'cms.plugins.picture', 'cms.plugins.snippet', 'cms.plugins.teaser', 'cms.plugins.text', #'cms.plugins.video', 'cms.plugins.twitter', 'filer', 'cmsplugin_filer_file', 'cmsplugin_filer_folder', 'cmsplugin_filer_image', 'cmsplugin_filer_teaser', 'cmsplugin_filer_video', 'easy_thumbnails', 'PIL', # Uncomment the next line to enable the admin: 'django.contrib.admin', # Uncomment the next line to enable admin documentation: # 'django.contrib.admindocs', ) # A sample logging configuration. The only tangible logging # performed by this configuration is to send an email to # the site admins on every HTTP 500 error when DEBUG=False. # See http://docs.djangoproject.com/en/dev/topics/logging for # more details on how to customize your logging configuration. LOGGING = { 'version': 1, 'disable_existing_loggers': False, 'filters': { 'require_debug_false': { '()': 'django.utils.log.RequireDebugFalse' } }, 'handlers': { 'mail_admins': { 'level': 'ERROR', 'filters': ['require_debug_false'], 'class': 'django.utils.log.AdminEmailHandler' } }, 'loggers': { 'django.request': { 'handlers': ['mail_admins'], 'level': 'ERROR', 'propagate': True, }, } } when i try to upload an image, in the clipboard section i don't have the thumbnail, but just an 'undefined' message: and this is the runserver console while trying to upload: [20/Oct/2012 15:15:56] "POST /admin/filer/clipboard/operations/upload/?qqfile=29708_1306856312320_7706073_n.jpg HTTP/1.1" 500 248133 [20/Oct/2012 15:15:56] "GET /it/admin/filer/folder/unfiled_images/undefined HTTP/1.1" 301 0 [20/Oct/2012 15:15:56] "GET /it/admin/filer/folder/unfiled_images/undefined/ HTTP/1.1" 404 1739 Also, this is project filesystem: cms1 +-- cms1 ¦   +-- __init__.py ¦   +-- __init__.pyc ¦   +-- media ¦   ¦   +-- filer_public ¦   ¦   +-- 2012 ¦   ¦   +-- 10 ¦   ¦   +-- 20 ¦   ¦   +-- 29708_1306856312320_7706073_n_1.jpg ¦   ¦   +-- 29708_1306856312320_7706073_n_2.jpg ¦   ¦   +-- 29708_1306856312320_7706073_n_3.jpg ¦   ¦   +-- 29708_1306856312320_7706073_n_4.jpg ¦   ¦   +-- 29708_1306856312320_7706073_n_5.jpg ¦   ¦   +-- 29708_1306856312320_7706073_n_6.jpg ¦   ¦   +-- 29708_1306856312320_7706073_n_7.jpg ¦   ¦   +-- 29708_1306856312320_7706073_n.jpg ¦   ¦   +-- torrent-client-macosx.jpg ¦   +-- settings.py ¦   +-- settings.pyc ¦   +-- static ¦   +-- static_auto ¦   +-- static_manual ¦   +-- templates ¦   ¦   +-- base.html ¦   ¦   +-- template_1.html ¦   ¦   +-- template_2.html ¦   +-- urls.py ¦   +-- urls.pyc ¦   +-- wsgi.py ¦   +-- wsgi.pyc +-- manage.py So files are uploaded, but they are not accessible to cms. there's a similar question here, but doens't help me so much. It would be very helpful any help on this issue to me. Thanks, luke

    Read the article

  • iOS app won't compile on device but works fine in simulator

    - by Jhorra
    I'm assuming this has something to do with linking, but I've removed RestKit and re-added it. I made sure all my connections and linking was in place. If I set XCode to use the simulator it runs fine, but as soon as I set it to run on any device it won't even build. The only other thing of note is this didn't start happening till I upgraded to XCode 4.5. Below are the errors it gives me ld: warning: ignoring file /Users/luke/Library/Developer/Xcode/DerivedData/ehrx-btsujlxuhtytahfaikwjeqfjybtt/Build/Products/Debug-iphoneos/libRestKit.a, file was built for archive which is not the architecture being linked (armv7s): /Users/luke/Library/Developer/Xcode/DerivedData/ehrx-btsujlxuhtytahfaikwjeqfjybtt/Build/Products/Debug-iphoneos/libRestKit.a Undefined symbols for architecture armv7s: "_OBJC_CLASS_$_RKClient", referenced from: objc-class-ref in ehrxAppDelegate.o objc-class-ref in ehrxLoginView.o objc-class-ref in ehrxInboxView.o objc-class-ref in ehrxCMView.o objc-class-ref in ehrxEncounterDemoView.o objc-class-ref in ehrxEncounterDiagListView.o objc-class-ref in ehrxEncounterChargeView.o ... ld: symbol(s) not found for architecture armv7s clang: error: linker command failed with exit code 1 (use -v to see invocation)

    Read the article

  • Disable local delivery in Sendmail

    - by Luke P M
    I am using Sendmail on a Centos server to send email for PHP scripts, but the problem is that mail is delivered to a local mailbox on the machine rather than what is specified in the MX records for the domain - which actually point to another machine I use for email. I would like sendmail to not try and locally deliver mail for the domain the machine is setup for, is there a simple way to disable local delivery? The domain is not in the local-host-names file. I've already done lots of googling and I have looked at: http://serverfault.com/questions/26934/sendmail-configuration-to-not-deliver-mail-to-local-machine http://serverfault.com/questions/65365/disable-local-delivery-in-sendmail But either there is no answer or it is not suitable. I don't want to relay to another server, i just want it to send mail regardless of domain. To provide an example: I have two servers, one is the mail server at mail.example.com and a web server which is example.com, when I use the smtp service on the web server it currently routes mail to a local mailbox on example.com, but it should be going to mailboxes on mail.example.com Output of sendmail -bt returns: ADDRESS TEST MODE (ruleset 3 NOT automatically invoked) Enter 3,0 [email protected] canonify input: info @ example . com Canonify2 input: info Canonify2 returns: info canonify returns: info parse input: info Parse0 input: info Parse0 returns: info ParseLocal input: info ParseLocal returns: info Parse1 input: info Parse1 returns: $# local $: info parse returns: $# local $: info

    Read the article

  • Hardware firewall vs VMWare firewall appliance

    - by Luke
    We have a debate in our office going on whether it's necessary to get a hardware firewall or set up a virtual one on our VMWare cluster. Our environment consists of 3 server nodes (16 cores w/ 64 GB RAM each) over 2x 1 GB switches w/ an iSCSI shared storage array. Assuming that we would be dedicating resources to the VMWare appliances, would we have any benefit of choosing a hardware firewall over a virtual one? If we choose to use a hardware firewall, how would a dedicated server firewall w/ something like ClearOS compare to a Cisco firewall?

    Read the article

  • Meaning of directories on Unix and Unix like systems

    - by Luke
    I've been using Linux for a couple of years now but I still haven't figured out what the origin or meaning of some the directory names are on Unix and Unix like systems. E.g. what does etc stand for or var? Where does the opt name come from? And while we're on the topic anyway. Can someone give a clear explanation of what directory is best used for what. I sometimes get confused where certain software is installed or what the most appropriate directory is to install software into.

    Read the article

  • IIS 7 Using Domain Account for Application pool identity Invalid Password

    - by Luke Van Diest
    I have an asp.net website containing a WCF service that I am developing on a Windows 7 machine hosted with IIS 7. I am needing to connect to an instance of Reporting Services 2005 with the service, and have been getting 401 errors when trying to execute reports. So, I assume that I need to be running the IIS Application pool under a domain account. The problem is that when I try to change the identity to a domain account, I get the error message "The specified password is invalid. Type a new password." I've rechecked the password multiple times to make sure it is correct. The account I'm using has admin rights on the machine. I saw elsewhere to try running this command: aspnet_regiis.exe -GA domain\username which I did but it didn't help. What else do I need to do?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >