<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[FrontAccounting forum — Can't Delete a company]]></title>
		<link>https://frontaccounting.com/punbb/viewtopic.php?id=513</link>
		<atom:link href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=513&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in Can't Delete a company.]]></description>
		<lastBuildDate>Thu, 13 Mar 2014 08:06:04 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=19500#p19500</link>
			<description><![CDATA[<p>Notes:</p><p>The php function <strong>rmdir</strong> can be used only if the directory is empty.</p><p>When safe mode is enabled, PHP checks whether the directory in which the script is operating has the same UID (owner) as the script that is being executed.</p>]]></description>
			<author><![CDATA[null@example.com (apmuthu)]]></author>
			<pubDate>Thu, 13 Mar 2014 08:06:04 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=19500#p19500</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=19495#p19495</link>
			<description><![CDATA[<p>You should also remove it from the file, config_db.php. Be careful, however, to delete the right things.</p><p>/Joe</p>]]></description>
			<author><![CDATA[null@example.com (joe)]]></author>
			<pubDate>Thu, 13 Mar 2014 06:30:58 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=19495#p19495</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=19485#p19485</link>
			<description><![CDATA[<div class="quotebox"><blockquote><p>Broken company subdirectories system. You have to remove this company manually.</p></blockquote></div><p>I stupidly deleted a company database from MySQL with phpAdmin. Not surprisingly, FA wouldn&#039;t delete the company. Then I deleted the .../company/1/ folder. Again, no go.</p><p>How do I now delete the company manually?</p>]]></description>
			<author><![CDATA[null@example.com (hfinger)]]></author>
			<pubDate>Thu, 13 Mar 2014 02:24:08 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=19485#p19485</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=12746#p12746</link>
			<description><![CDATA[<p>Yes, this is exactly how it works. Directory name is&nbsp; not database prefix but company index in $db_connections table.<br />Janusz</p>]]></description>
			<author><![CDATA[null@example.com (itronics)]]></author>
			<pubDate>Fri, 22 Jun 2012 12:48:32 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=12746#p12746</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=12744#p12744</link>
			<description><![CDATA[<p>Thanks Janusz!</p><p>I did a:</p><div class="codebox"><pre><code># pwd
/var/www/fa/company
# mkdir -p 1 2 3
# chmod -Rv 777 *</code></pre></div><p>Then logged into FA as admin and deleted company 2 and 3 no problem. Company 4 is now effectively company 2 using the /var/www/htdocs/fa/company/1 directory.</p><p>That did the trick. Of interesting note is that what was previously company 4, which had the table prefix 3_, still has the same prefix (Like you said it has nothing to do with the ...fa/company/ directory tree naming scheme), and after deleting company 2 and company 3 it still retains the same table prefix, which I believe is what you were trying to explain in another post above.</p><p>Once again, </p><p>Thanks <img src="https://frontaccounting.com/punbb/img/smilies/smile.png" width="15" height="15" alt="smile" /></p>]]></description>
			<author><![CDATA[null@example.com (tallship)]]></author>
			<pubDate>Fri, 22 Jun 2012 04:31:31 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=12744#p12744</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=12741#p12741</link>
			<description><![CDATA[<p>Well, this is quite simple: if you have 3 companies in your config_db.php fiel, you should have 3 private folders under company, named &#039;0&#039; to &#039;2&#039;. If for some reason anyone subfolder is missing the company deletion fails. This is because folders have to renumbered&nbsp; when you delete any but the last one company (e.g. removing company 1 will require renaming the &#039;2&#039; folder to &#039;1&#039;). This cannot be done when some folder is missing.</p><p>Janusz</p>]]></description>
			<author><![CDATA[null@example.com (itronics)]]></author>
			<pubDate>Thu, 21 Jun 2012 19:32:39 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=12741#p12741</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=12735#p12735</link>
			<description><![CDATA[<div class="quotebox"><cite>itronics wrote:</cite><blockquote><p>Nothing has changed in this matter so far, answer to your question you can find in second post in this thread. <br />Janusz</p></blockquote></div><p>Okay I saw that there was one file there that wasn&#039;t chmod&#039;d 777:</p><div class="codebox"><pre><code>-rw-r--r-- 1 apache apache  147 Nov 28  2011 installed_extensions.php</code></pre></div><p>So I set it 777. When that didn&#039;t work I:</p><div class="codebox"><pre><code>root@hammer:/var/www/htdocs/fa/company# chmod -Rv 777 .</code></pre></div><p>And I still got the same error when trying to remove a company.</p><p>So finally I set everything from the DocumentRoot of the FA installation (/var/www/htdocs/fa) on down as 777 and still I&#039;m receiving the same error.</p><p>Everything in the entire FA installation, all directories and files, to 777</p><p>What should I look at trying next?</p><p>Thanks )</p>]]></description>
			<author><![CDATA[null@example.com (tallship)]]></author>
			<pubDate>Wed, 20 Jun 2012 22:18:08 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=12735#p12735</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=12734#p12734</link>
			<description><![CDATA[<p>Nothing has changed in this matter so far, answer to your question you can find in second post in this thread. <br />Janusz</p>]]></description>
			<author><![CDATA[null@example.com (itronics)]]></author>
			<pubDate>Wed, 20 Jun 2012 19:11:28 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=12734#p12734</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=12728#p12728</link>
			<description><![CDATA[<p>I&#039;m getting that same error:</p><div class="quotebox"><blockquote><p>Broken company subdirectories system. You have to remove this company manually.</p></blockquote></div><p>This is what my directory tree looks like with 4 companies:</p><div class="codebox"><pre><code>root@hammer:/var/www/htdocs/fa/company# ls
0/  index.php*
root@hammer:/var/www/htdocs/fa/company# ls 0
backup/  images/  index.php*  installed_extensions.php  js_cache/  pdf_files/  reporting/
root@hammer:/var/www/htdocs/fa/company# ls -la  
total 16
drwxr-xr-x  3 root root 4096 Nov 27  2011 ./
drwxrwxrwx 23 root root 4096 Nov 28  2011 ../
drwxrwxrwx  7 root root 4096 Nov 28  2011 0/
-rwxrwxrwx  1 root root   43 Nov 24  2011 index.php*
root@hammer:/var/www/htdocs/fa/company# ls -la 0
total 36
drwxrwxrwx 7 root   root   4096 Nov 28  2011 ./
drwxr-xr-x 3 root   root   4096 Nov 27  2011 ../
drwxrwxrwx 2 root   root   4096 Nov 28  2011 backup/
drwxrwxrwx 2 root   root   4096 Nov 28  2011 images/
-rwxrwxrwx 1 root   root     43 Nov 24  2011 index.php*
-rw-r--r-- 1 apache apache  147 Nov 28  2011 installed_extensions.php
drwxrwxrwx 2 root   root   4096 Jun 10 00:05 js_cache/
drwxrwxrwx 2 root   root   4096 Nov 28  2011 pdf_files/
drwxrwxrwx 2 root   root   4096 Nov 27  2011 reporting/</code></pre></div><p>I only see one directory there, and I&#039;m running FrontAccounting 2.3.9.</p><p>Shouldn&#039;t there be a company/1, company/2, and company/3 directory?</p><p>What&#039;s the next thing to look at for manually removing a company?</p><p>Thanks <img src="https://frontaccounting.com/punbb/img/smilies/smile.png" width="15" height="15" alt="smile" /></p>]]></description>
			<author><![CDATA[null@example.com (tallship)]]></author>
			<pubDate>Wed, 20 Jun 2012 05:18:43 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=12728#p12728</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=3270#p3270</link>
			<description><![CDATA[<p>I think the code uses rmdir, which should be replaced by a recursive delete. That fixed the problem in my case.</p>]]></description>
			<author><![CDATA[null@example.com (ddecock)]]></author>
			<pubDate>Wed, 19 Aug 2009 08:27:35 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=3270#p3270</guid>
		</item>
		<item>
			<title><![CDATA[Re: Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=1976#p1976</link>
			<description><![CDATA[<p>Probably you are using old database on new source tree, where per company subtree is deleted on made unwritable for www server. The subdirectories should have sequential integer numbers beginning from 0 (this has nothing to do with database prefix!). So if you have 5 entries in db_connections (config_db.php) you should have 5 subdirectories from company/0 to company/4. After restoring check if all files have 777 access rights set then delete unneeded company in Create/Update Company page.<br />Janusz</p>]]></description>
			<author><![CDATA[null@example.com (itronics)]]></author>
			<pubDate>Thu, 12 Mar 2009 09:08:13 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=1976#p1976</guid>
		</item>
		<item>
			<title><![CDATA[Can't Delete a company]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=1973#p1973</link>
			<description><![CDATA[<p>I have been testing out Front Accounting and adding multiple companies in the process.<br />However, I can&#039;t delete any of these companies in the Create/Update company area.</p><p>It keeps giving me a message saying &quot;Cannont remove company data directory ../company/5&quot;&nbsp; or 6 or whatever company number I am trying to delete.</p><p>Please let me know what I need to do to delete these extra companies without having to manually go into the database and remove the tables and directories that were created when setting up a new company.</p><p>Thanks,<br />Dave</p>]]></description>
			<author><![CDATA[null@example.com (bruzergear)]]></author>
			<pubDate>Thu, 12 Mar 2009 04:36:54 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=1973#p1973</guid>
		</item>
	</channel>
</rss>
