Answers.Body: <p>From searching the files (i.e. 'craft/app/Craft.php' line 124) it looks like you can get it using:</p>
  
  <pre><code>craft()-&gt;getSiteName()
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-11-24T16:08:53.567Z
Answers.Text: Or, as with most things Craft, without the method call `craft()->siteName`.
Answers.UserDisplayName: Joshua Baker
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-11-23T23:22:35.457Z
Answers.LastActivityDate: 2014-11-23T23:22:35.457Z
Answers.UserDisplayName: Douglas McDonald
Body: <p>I'm sure it's obvious, but how do I get the current site name from within a plugin?</p>
  
  <p>I tried a few things, including</p>
  
  <pre><code>craft()-&gt;systemSettings-&gt;getSettings('general')
  </code></pre>
  
  <p>Any ideas?</p>
  
Tags: <plugin-development>
Title: SiteName in a plugin?
ThreadText: # SiteName in a plugin?
  
  (Asked by: username_0 on 2014-11-23)
  
  I'm sure it's obvious, but how do I get the current site name from within a plugin?
  
  I tried a few things, including
  
  ```
  craft()->systemSettings->getSettings('general')
  
  ```
  
  Any ideas?
  
  **Tags:** plugin-development
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2014-11-23. Score: 4
  
  From searching the files (i.e. 'craft/app/Craft.php' line 124) it looks like you can get it using:
  
  ```
  craft()->getSiteName()
  
  ```
  
  > **Comments:**
  > **username_2**: Or, as with most things Craft, without the method call `craft()->siteName`.  
  
  ---
  
  