Writing thesis in overleaf. How to create a sub-folder?

I'm using the template of University of Bristol Thesis on overleaf.com. I'd like to create a folder of chapter02 inside the folder of chapters. But I can't seem to do so. I can manually add a new folder but it goes to files rather than goes inside a specific folder chapters.

This doesn't work for me.

Below is the code of template. I'm confused of input and import command.

\import{chapters/chapter02/} %or
\input{chapters/chapter02/}


But they don't work. I got error message

 ! LaTeX Error: File chapters/chapter02/.tex' not found.
l.373 \input{chapters/chapter02/}
{chap02.tex}^^M


Example：

%\title{University of Bristol Thesis Template}
\begin{document}
\frontmatter
\pagenumbering{roman}
\input{frontmatter/title}
\input{frontmatter/abstract}
\input{frontmatter/dedication}
\input{frontmatter/declaration}
\maxtocdepth{subsection}
\tableofcontents*
\listoftables
\listoffigures
\mainmatter
\import{chapters/chapter01/}{chap01.tex}
% Here neither input nor import don't work.
% \input{chapters/chapter02/}
% \import{chapters/chapter02/}
\appendix
\import{chapters/appendices/}{app0A.tex}
\backmatter
\bibliographystyle{siam}
\refstepcounter{chapter}
\bibliography{thesisbiblio}
\end{document}


Update: Thanks for all the help. There is a tip to create sub folder on Overleaf. See @LianTze Lim's reply.

• Like I wrote, the command \input{chapters/chapter02/}{chap02.tex} would NEVER work, since that's not the correct syntax. Please stop showing the error output for THAT command, and instead show the error output if you replace it by one of \input{chapters/chapter02/chap02} (exactly as I wrote here) or \import{chapters/chapter02/}{chap02.tex}. – Willie Wong Jun 6 '16 at 19:31
• I wouldn't use a template. – Johannes_B Jun 6 '16 at 19:38
• Ah, I think this is the relevant quote: "chap02.tex doesn't exist. I'm just trying to add a folder of chapter02 under the folder chapters here. " The short version is "don't do that." The slightly longer version is "you can do that if you create the file chap02.tex; you can even leave it empty. But it has to be there." – Willie Wong Jun 6 '16 at 19:55
• Two years ago there was no official UoB template. A few unofficial templates were kicking around but I was unimpressed. – Chris H Jun 6 '16 at 20:02
• @Sile_Li Now it appears you are asking about the user interface for Overleaf.com. I am not familiar with it so I cannot help necessarily. But have you tried following the instruction here to create a folder/subfolder? You don't create a folder by putting in TeX code. TeX doesn't do that. You create a folder using the Overleaf (or whatever operating system/interface) and read files from the folder using TeX. – Willie Wong Jun 6 '16 at 21:21

\documentclass[12pt,a4paper]{book}
\usepackage[latin1]{inputenc}

\begin{document}

%% 01 is .tex file inside the shown hierarchy
\input{Chapters/chapter01/01}
\input{Chapters/chapter02/02}
\input{Chapters/chapter03/03

\end{document}


and you could do

\chapter{Intro}
...


for 01.tex and other files.

Look on the wiki here for further details.

If you have another problem, post a MWE and the error message.

Edited after MWE:

You are doing

\input{chapters/chapter02/}{chap02.tex}


This is not right syntax. Use

\input{chapters/chapter02/chap02.tex}


• @Sile_Li When you create the empty folder chapters/chapter02 on Overleaf, it shows up as a "flat" folder directly under the main folder. But if you add a file to this new folder, the file hierarchy would then fall into place correctly. Alternatively, you can also add a blank file in the chapters folder, but give it the name chapter02/chap02.tex. That would also immediately make the file hierarchy fall into place. Here's an animated GIF to help make things clearer: dropbox.com/s/twgkg06f3ayoinz/sileli-subfolders.gif?dl=0 – LianTze Lim Jun 7 '16 at 0:23