Search Results

Search found 329 results on 14 pages for 'neil mcf'.

Page 11/14 | < Previous Page | 7 8 9 10 11 12 13 14  | Next Page >

  • Mysql search design

    - by neil
    I'm designing a mysql database, and i'd like some input on an efficient way to store blog/article data for searching. Right now, I've made a separate column that stores the content to be searched - no duplicate words, no words shorter than four letters, and no words that are too common. So, essentially, it's a list of keywords from the original article. Also searched would be a list of tags, and the title field. I'm not quite sure how mysql indexes fulltext columns, so would storing the data like that be ineffective, or redundant somehow? A lot of the articles are on the same topic, so would the score be hurt by so many of the rows having similar keywords? Also, for this project, solutions like sphinx, lucene or google custom seach can't be used -- only php & mysql. Thanks!

    Read the article

  • Classic ASP shopping cart discounts

    - by Neil Bradley
    Hi there, I have a Classic ASP shopping cart, but I need to add in an option to enter a promo code and (if valid) apply a discount to the total. There is a promo codes table that stores the promotional codes and the value of the discount to apply. So I was wondering if someone might be able to help me integrate this? Happy to pay for the time. I think it may only take an hour or so at most. :S

    Read the article

  • Evaluating IIS7 with Virtual PC?

    - by Neil
    Hi, I wanna do some local developer tests of IIS 7 but I don't have Windows Vista, 7 or 2008 server - I currently run XP SP3. I have Virtual PC installed so I can use Microsoft's IE compatibility images - are there any time-limited images that I can use with Virtual PC so I can check out IIS 7? The IIS 7 "Try it" link points to this page. But the VHS is for Windows Server platforms only I think and I don't want an ISO? Any advice?

    Read the article

  • What is the difference between type.__getattribute__ and object.__getattribute__?

    - by Neil G
    Given: In [37]: class A: ....: f = 1 ....: In [38]: class B(A): ....: pass ....: In [39]: getattr(B, 'f') Out[39]: 1 Okay, that either calls super or crawls the mro? In [40]: getattr(A, 'f') Out[40]: 1 This is expected. In [41]: object.__getattribute__(A, 'f') Out[41]: 1 In [42]: object.__getattribute__(B, 'f') --------------------------------------------------------------------------- AttributeError Traceback (most recent call last) <ipython-input-42-de76df798d1d> in <module>() ----> 1 object.__getattribute__(B, 'f') AttributeError: 'type' object has no attribute 'f' What is getattribute not doing that getattr does? In [43]: type.__getattribute__(B, 'f') Out[43]: 1 What?! type.__getattribute__ calls super but object's version doesn't? In [44]: type.__getattribute__(A, 'f') Out[44]: 1

    Read the article

  • Preparing for the next C++ standard

    - by Neil Butterworth
    The spate of questions regarding BOOST_FOREACH prompts me to ask users of the Boost library what (if anything) they are doing to prepare their code for portability to the proposed new C++ standard (aka C++0x). For example, do you write code like this if you use shared_ptr: #ifdef CPPOX #include <memory> #else #include "boost/shared_ptr.hpp" #endif There is also the namespace issue - in the future, shared_ptr will be part of the std, namespace - how do you deal with that? I'm interested in these questions because I've decided to bite the bullet and start learning boost seriously, and I'd like to use best practices in my code. Not exactly a flood of answers - does this mean it's a non-issue? Anyway, thanks to those that replied; I'm accepting jalfs answer because I like being advised to do nothing!

    Read the article

  • Configuring log4j at runtime

    - by Neil
    I'm using org.apache.tools.ant.listener.Log4jListener to manage logging with my ant script. The ant script is highly configurable and designed to be run different ways with different parameters and therefore I need to be able to log to files specified at runtime. I have a log4j.properties which specifies a log file to be build.log, and despite my attempts to launch ant redefining properties defined in log4j.properties have been unsuccessful. The build ignores them and continues to write to build.log. I haven't found much support regarding writing to custom files unless it's in Java with their Logger class. Perhaps I'm thinking this through wrong. log4j.properties isn't treated in the same way as a property file in an ant script (hence overrideable from the command line)? Is there a way I can do this intelligently without writing a custom task or something?

    Read the article

  • Is there an existing delegate in the .NET Framework for comparison?

    - by Neil Barnwell
    The .NET framework provides a few handy general-use delegates for common tasks, such as Predicate<T> and EventHandler<T>. Is there a built-in delegate for the equivalent of CompareTo()? The signature might be something like this: delegate int Comparison<T>(T x, T y); This is to implement sorting in such a way that I can provide a lambda expression for the actual sort routine (ListView.ListViewItemSorter, specifically), so any other approaches welcome.

    Read the article

  • Is there any mercurial hosting actually *on* Amazon EC2?

    - by Neil Trodden
    I need to be able to update my ec2 instance from a label in mercurial when it resets so my application is always set at the right revision. It'd be great to be able to push my changes to a mercurial host and have my instances automatically update across the ec2 network when they are reset! I really don't want to host mercurial on the same instance (or even a dedicated instance)

    Read the article

  • SEO URL Structure

    - by Neil
    Based on the following example URL structure: mysite.com/mypage.aspx?a=red&b=green&c=blue Pages in the application use ASP.net user controls and some of these controls build a query string. To prevent duplicate keys being created e.g. &pid=12&pid=10, I am researching methods of rewriting the URL: a) mysite.com/mypage.aspx/red/green/blue b) mysite.com/mypage.aspx?controlname=a,red|b,green|c,blue Pages using this structure would be publishing content that I would like to get indexed and ranked - articles and products (8,000 products to start, with thousands more being added later) My gut instinct tells me to go with the first method, but would it would be overkill to add all that infrastructure if the second method will accomplish my goal of getting pages indexed AND ranked. So my question, looking at the pro's and con's, Google Ranking, time to implement etc. which method should I use? Thanks!

    Read the article

  • Deep relationships in Rails

    - by Neil Middleton
    I have some projects. Those projects have users through memberships. However, those users belong to companies. Question is, how do I find out which companies can access a project? Ideally I'd be able to do project.users.companies, but that won't work. Is there a nice, pleasant way of doing this?

    Read the article

  • Can I reverse the order of a multicast delegate event?

    - by Neil Barnwell
    When you subscribe to an event in .NET, the subscription is added to a multicast delegate. When the event is fired, the delegates are called in the order they were subscribed. I'd like to override the subscription somehow, so that the subscriptions are actually fired in the reverse order. Can this be done, and how? I think something like this might be what I need?: public event MyReversedEvent { add { /* magic! */ } remove { /* magic! */ } }

    Read the article

  • Undocumented overload of string.Split() ?

    - by Neil N
    According to both Intellisense and MSDN doc on string.Split, there are no parameterless overloads of string.Split. Yet if I type in string[] foo = bar.Split(); It compiles. And it works. I have verified this in both Visual Studio 2008 and 2010. In both cases intellisense does not show the parameterless overload. Is there a reason for this? Are there any other missing overloads from the MSDN/Intellisense docs? Usually browsing through overloads in intellisense is how I best determine which overload to use. I'd hate to think I am missing other available options throughout the .Net framework.

    Read the article

  • Embarassing C++ question regarding const

    - by Neil Butterworth
    My comments on this answer got me thinking about the issues of constness and sorting. I played around a bit and reduced my issues to the fact that this code: #include <vector> int main() { std::vector <const int> v; } will not compile - you can't create a vector of const ints. I suppose I should have known this, but I've never needed to create such a thing before. However, it seems like a useful construct to me, and I wonder if there is any way round this problem - I want to add things to a vector (or whatever), but they should not be changed once added. There's probably some embarrassingly simple solution to this, but it's something I'd never considered before.

    Read the article

  • Using ffmpeg to cut up video

    - by Neil
    I am using FFmpeg like this e.g.: ffmpeg -i input.wmv -ss 60 -t 60 -acodec copy -vcodec copy output.wmv to cut out a section of a large file. The -ss part works fine but the -t is ignored. That is, it correctly removes the first -ss seconds but then just keeps going to the end of the input with the copy. Is there a way to use FFmpeg to cut off the end of a video without recoding it?

    Read the article

  • Adding a LIKE criteria to a Rails Conditions block

    - by Neil Middleton
    Consider the following code which is to be thrown at an AR find: conditions = [] conditions[:age] = params[:age] if params[:age].present? conditions[:gender] = params[:gender] if params[:gender].present? I need to add another condition which is a LIKE criteria on a 'profile' attribute. How can I do this, as obviously a LIKE is usually done via an array, not a hash key.

    Read the article

  • cannot get FilesMatch and mod_rewrite working together

    - by neil
    Hello, I'm having a little difficulty with my .htaccess when combining a password protection on a file and a mod_rewrite: If I only have this as my .htaccess <FilesMatch "manage.php"> AuthName "Member Only" AuthType Basic AuthUserFile /home/myuser/.htpasswd require valid-user </FilesMatch> It password protects manage.php fine. If I have this as my .htaccess RewriteEngine on RewriteCond $1 !^(index\.php|manage\.php|robots\.txt) RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php/$1 [L,QSA] It works as expected: robots.txt, index.php and manage.php are left alone and are called as normal, everything else is redirected to index.php/$1 HOWEVER, If I combine them then when I visit manage.php it gets redirected as index.php/$1, i.e. the FilesMatch is causing the entry in rewritecond to be ignored. If I actually enter a password in the original test and get to the file, it works in this last test. So I guess something is up with the rewrite and the file match. i.e. entering this causes .\manage.php to be called as .\index.php\manage.php <FilesMatch "manage.php"> AuthName "Member Only" AuthType Basic AuthUserFile /home/myuser/.htpasswd require valid-user </FilesMatch> RewriteEngine on RewriteCond $1 !^(index\.php|manage\.php|robots\.txt) RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php/$1 [L,QSA] Thanks for any help :)

    Read the article

  • Can MySQL automatically specify `_utf8` for inserts to UTF-8 columns?

    - by Neil
    I have a table like this, where one column is latin1, the other is UTF-8: Create Table: CREATE TABLE `names` ( `name_english` varchar(255) character NOT NULL, `name_chinese` varchar(255) character set utf8 default NULL, ) ENGINE=MyISAM DEFAULT CHARSET=latin1 When I do an insert, I have to type _utf8 before values being inserted into UTF-8 columns: insert into names (name_english = "hooey", name_chinese = _utf8 "??"); However, since MySQL should know that name_chinese is a UTF-8 column, it should be able to know to use _utf8 automatically. Is there any way to tell MySQL to use _utf8 automatically, so when I'm programatically making prepared statements, I don't have to worry about including it with the right parameters?

    Read the article

  • Adding data sources for unixODBC/isql on Mac OSX Lion

    - by NP01
    I have installed unixODBC from source and mysql-odbc connector from .dmg installer on Mac OSX Lion. This was done a while ago, and at that time I successfully installed a data source (let's call it foo). Now I am trying to add another data source (DSN). I've done this through both ODBC Manager and the command-line tool myodbc-installer given with the tar bundle of the mysql-odbc connector from the mysql website. An entry shows up in /Library/ODBC/odbc.ini, which looks like this: [ODBC Data Sources] bar = MySQL ODBC 5.1 Driver [ODBC] Trace = 0 TraceAutoStop = 0 TraceFile = TraceLibrary = [myodbc] Driver = /usr/local/lib/libmyodbc5.so SERVER = localhost PORT = 3306 [bar] Driver = /usr/local/lib/libmyodbc5.so Description = DATABASE = bar However, isql fails to find it: anitya:Preferences neil$ isql bar bar bar -v [IM002][unixODBC][Driver Manager]Data source name not found, and no default driver specified [ISQL]ERROR: Could not SQLConnect Weird thing is, the old DSN foo, which is not to be seen in /Library/ODBC/odbc.ini or /etc/odbc.ini, works fine: anitya:Preferences neil$ isql foo foo foo +---------------------------------------+ | Connected! | | | | sql-statement | | help [tablename] | | quit | | | +---------------------------------------+ SQL> I'm miffed about where the DSN entries need to be entered on OSX Lion to be found by isql. Thanks in advance for your help!

    Read the article

  • Win XP error 0x80041003 using GetObject/winmgmts

    - by John Lewis
    My computer is called "neil" and I want to set some values using WMI in vbScript. I adapetd the script below from one supplied by Microsoft. When I run it in my browser I get Error Type: (0x80041003) /dressage/30/pdf2.asp, line 8 I suspect it is some registry/security setting. Any advice? John Lewis FULL SCRIPT call Print_HTML_Page("http://neil/dressage/ascii.asp", "ascii") Sub SetPDFFile(strPDFFile) Const HKEY_LOCAL_MACHINE = &H80000002 strKeyPath = "SOFTWARE\Dane Prairie Systems\Win2PDF" strComputer = "." Set objReg=GetObject( _ "winmgmts:{impersonationLevel=impersonate}!\\" & _ strComputer & "\root\default:StdRegProv") strValueName = "PDFFileName" objReg.SetExpandedStringValue HKEY_LOCAL_MACHINE,_ strKeyPath,strValueName,strPDFFile End Sub Sub Print_HTML_Page(strPathToPage, strPDFFile) SetPDFFile( strPDFFile ) Set objIE = CreateObject("InternetExplorer.Application") 'From http://www.tek-tips.com/viewthread.cfm?qid=1092473&page=5 On Error Resume Next strPrintStatus = objIE.QueryStatusWB(6) If Err.Number 0 Then MsgBox "Cannot find a printer. Operation aborted." objIE.Quit Set objIE = Nothing Exit Sub End If With objIE .visible=0 .left=200 .top=200 .height=400 .width=400 .menubar=0 .toolbar=1 .statusBar=0 .navigate strPathToPage End With 'Wait until IE has finished loading Do while objIE.busy WScript.Sleep 100 Loop On Error Goto 0 objIE.ExecWB 6,2 'Wait until IE has finished printing WScript.Sleep 2000 objIE.Quit Set objIE = Nothing End Sub

    Read the article

  • Android - Key Dispatching Timed Out

    - by Donal Rafferty
    In my Android application I am getting a very strange crash, when I press a button (Image) on my UI the entire application freezes and after a couple of seconds I getthe dreaded force close dialog appearing. Here is what gets printed in the log: WARN/WindowManager(88): Key dispatching timed out sending to package name/Activity WARN/WindowManager(88): Dispatch state: {{KeyEvent{action=1 code=5 repeat=0 meta=0 scancode=231 mFlags=8} to Window{432bafa0 com.android.launcher/com.android.launcher.Launcher paused=false} @ 1281611789339 lw=Window{432bafa0 com.android.launcher/com.android.launcher.Launcher paused=false} lb=android.os.BinderProxy@431ee8e8 fin=false gfw=true ed=true tts=0 wf=false fp=false mcf=Window{4335fc58 package name/Activity paused=false}}} WARN/WindowManager(88): Current state: {{null to Window{4335fc58 package name/Activity paused=false} @ 1281611821193 lw=Window{4335fc58 package name/Activity paused=false} lb=android.os.BinderProxy@434c9bd0 fin=false gfw=true ed=true tts=0 wf=false fp=false mcf=Window{4335fc58 package name/Activity paused=false}}} INFO/ActivityManager(88): ANR in process: package name (last in package name) INFO/ActivityManager(88): Annotation: keyDispatchingTimedOut INFO/ActivityManager(88): CPU usage: INFO/ActivityManager(88): Load: 5.18 / 5.1 / 4.75 INFO/ActivityManager(88): CPU usage from 7373ms to 1195ms ago: INFO/ActivityManager(88): package name: 6% = 1% user + 5% kernel / faults: 7 minor INFO/ActivityManager(88): system_server: 5% = 4% user + 1% kernel / faults: 27 minor INFO/ActivityManager(88): tiwlan_wifi_wq: 3% = 0% user + 3% kernel INFO/ActivityManager(88): mediaserver: 0% = 0% user + 0% kernel INFO/ActivityManager(88): logcat: 0% = 0% user + 0% kernel INFO/ActivityManager(88): TOTAL: 12% = 5% user + 6% kernel + 0% softirq INFO/ActivityManager(88): Removing old ANR trace file from /data/anr/traces.txt INFO/Process(88): Sending signal. PID: 1812 SIG: 3 INFO/dalvikvm(1812): threadid=7: reacting to signal 3 INFO/dalvikvm(1812): Wrote stack trace to '/data/anr/traces.txt' This is the code for the Button (Image): findViewById(R.id.endcallimage).setOnClickListener(new OnClickListener() { public void onClick(View v) { mNotificationManager.cancel(2); Log.d("Handler", "Endcallimage pressed"); if(callConnected) elapsedTimeBeforePause = SystemClock.elapsedRealtime() - stopWatch.getBase(); try { serviceBinder.endCall(lineId); } catch (RemoteException e) { e.printStackTrace(); } dispatchKeyEvent(new KeyEvent(KeyEvent.ACTION_DOWN,KeyEvent.FLAG_SOFT_KEYBOARD)); dispatchKeyEvent(new KeyEvent(KeyEvent.ACTION_UP, KeyEvent.KEYCODE_BACK)); } }); If I comment the following out the pressing of the button (image) doesn't cause the crash: try { serviceBinder.endCall(lineId); } catch (RemoteException e) { e.printStackTrace(); } The above code calls down through several levels of the app and into the native layer (NDK), could the call passing through several objects be leading to the force close? It seems unlikely as several other buttons do the same without issue. How about the native layer? Could some code I've built with the NDK be causing the issue? Any other ideas as to what the cause of the issue might be?

    Read the article

  • What is the right path for PHP includes on a Mac?

    - by skorned
    Running Mac OS X 10.5.8, with PHP 5.2.11 Pre-installed. Using Coda 1.6.10. I'm writing PHP files, and then preview them running from file, not server. This was working fine till I tried PHP includes. These don't work as a relative path, only as an absolute from the root of the drive. Is there any way I can use statements like include_once "common/header.php"; without specifying my entire file path like so : include_once "/Volumes/Macintosh HD/Users/neil/Desktop/Website/ColoredLists_v1.0/common/base.php"; ,where ColoredLists_v1.0 is the directory with all the website files in it. I tried solutions like prepending _SERVER[DOCUMENT_ROOT] or dirname(File) to the file paths, but that didn't work as the variables were not set. Is there any easy way to do this, or a configuration I can change so that it looks in a specific directory by default instead of looking at the drive root? Currently, echo_include_path shows .: When I include this line at the start of the script, it works: set_include_path('/Volumes/Macintosh HD/Users/neil/Desktop/Website/ColoredLists_v1.0'); However, if I want to do this for all my scripts, I can't seem to make the change permanent. Even after I edited the Unix include_path in my php.ini, it doesn't seem to work.

    Read the article

  • Zimbra server status showing red in control panel

    - by Debianuser
    I have been having a weird problem with Zimbra(7.1.4_GA_2555.DEBIAN5) lately: On the (web)control panel the status keep changing to red every few days. When this is happens the output of zmcontrol status still shows running: antispam Running antivirus Running imapproxy Running ldap Running logger Running mailbox Running memcached Running mta Running snmp Running spell Running stats Running zmconfigd Running Every thing runs fine except automated mail forwarding from one account to another(which is critical for us). I have been through Zimbra forums and the following ALWAYS fixes the issue: su - zimbra -c "zmprov mcf zimbraLogHostname mail.mydomain.com" /opt/zimbra/libexec/zmsyslogsetup /etc/init.d/rsyslog restart su - zimbra -c "zmcontrol restart" After I run the above commands, the status on control panel turns green and mail forwarding starts to work again BUT only for a few days. Other than the above, everything works fine including Server statistics. Anyone seen this issue before?

    Read the article

  • How to enable an external USD harddrive with ubuntu

    - by LarsOn
    Hello I'm trying to install a new LaCie Hard Disk design by Neil Poulton 1TB USB 2.0 GParted reports /dev/sda1 (with exclamation mark and key sign) ntfs 1 KiB unallocated 320 MiB /dev/sda2 hfs+ 2.84 MiB unallocated 931.2 GiB When trying to create a partition with Disk Utility it says Daemon is inhibited It seems I can't create the partition that way. Can you recommend how I can proceed? Thank you

    Read the article

  • How to Enable an External USB Hard Drive with Ubuntu

    - by LarsOn
    I'm trying to install a new LaCie Hard Disk design by Neil Poulton 1TB USB 2.0. GParted reports /dev/sda1 (with exclamation mark and key sign) ntfs 1 KiB unallocated 320 MiB /dev/sda2 hfs+ 2.84 MiB unallocated 931.2 GiB When trying to create a partition with Disk Utility it says Daemon is inhibited It seems I can't create the partition that way. Can you recommend how I can proceed? Thank you

    Read the article

< Previous Page | 7 8 9 10 11 12 13 14  | Next Page >